select in form
select in form
sitoryu
Posts: 5Questions: 1Answers: 0
hello, I need put select(dropdown) to editable form in "editor".
do someone have example?
Tnx
This discussion has been closed.
Replies
Thank you for quick responce
I find examples, but still with problem - I couldn't send correct from server side(PHP) the option of element that will be automaticly seleceted in JS*
php:
array(
"id" => (int)$val['id'],
"name" => $val['name'],
"email" => $val['email'],
"category" => $val['category'],
"password" => $val['password'],
"status" => (int)$val['status']
)
js:
label: "category:",
name: 'category',
type: "select",
options: [
{ label: "regular", value: "1" },
{ label: "VIP", value: "2" },
{ label: "another", value: "3" }
]
Yes - the
select
field is the way to do this.If this example doesn't help to resolve the problem, could you post your full Javascript code please, and also the JSON response from the server when loading the data?
Allan