sytanx question

in a template file login.rhtml: <%= form.password_field :password, :size => 40 %>

and i get this error:

undefined method `password' for #<User:0x47e5bcc

what is this supposed to mean?
and somebody please explain this syntax: Method :password
should not it be: Method :password=value?

in a template file login.rhtml: <%= form.password_field :password, :size => 40 %>

and i get this error: undefined method `password' for #<User:0x47e5bcc

It tried to call the password method on User, but couldn't.

what is this supposed to mean?

and somebody please explain this syntax: Method :password should not it be: Method :password=value?

Not sure what you're trying to ask

Hi,

Taken at face value, it looks like your User model doesn't have a password attribute. My reaction would be to check the spelling of the password field in the database table "users" and if that checks out, place a debug debugger breakpoint in the form and have a quick look at the User object.

HTH

Chris

thanks. i tried to debug as you said, it really helps.