Forum: Rails-ES date_select(how can i display in edit option)

Posted by Sundhari Bala (sundhari)
on 2010-12-23 12:59
add option syntax in view file:

 <%= date_select :users, :date_of_birth, :order => [:day, :month,
:year], :start_year => 1910 %>

This is my controller code:

@user.date_of_birth =
Date.new(params[:users]'date_of_birth(1i)'].to_i,params[:users]'date_of_birth(2i)'].to_i,params[:users]['date_of_birth(3i)'].to_i)

This is working perfect.

How can I use this date_select in edit option.(Example for view file and
controller codes )

Please, send me the reply...

Thanks,
B.Sundhari
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
No account? Register here.