[Rails] how to access the contents of a field
hello every body i have a simple question .
i have this form :
<%= form_tag :action=>'password' %>
Password:<%= password_field :p , :pass1 , :size=>'20'%>
Again:<%= password_field :p , :pass2 , :size=>'20'%>
how can i access the contents of the two field in ruby ?
by doing this : ch1=params[:p][:pass1] i have an error
You have a nil object when you didn't expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]
thanks :)
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home