Dear All.
I use this code for my project,
<%= collection_select(:zone_id , :name, @zones, :id,
:name,{},{:name=>'normalSelect'}) %>
with this. ruby on rails define default name and id.
Can i change default name to my custom name.
Regards,
D2M
on 2012-12-29 04:46
on 2012-12-29 05:05
Ok, I got with this code..
<%= collection_select(:question , :text, Question.all , :id, :text,
{:prompt => 'Select Question...'}, {:class=>'input',
:name=>'normalSelect'}) %>
Please log in before posting. Registration is free and takes only a minute.
Existing account
(Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
Log in with Google account | Log in with Yahoo account
No account? Register here.