I have a form where you sign up for an account on my RoR site. I have checks to make sure each text box has data in it. If I submit the form with all empty boxes, the page will be refreshed with errors (userID cannot be blank, email cannot be blank, etc.) Which is fine, but the password field is filled with asterisks. I think that its the encrypted 'blank' password that shows up. How can I get it to be blank? Thanks a lot Arthur
on 2007-04-11 17:14
on 2007-12-14 16:51
I have the same problem. I have a registration, checking with validates_confirmation_of if the pwd and the pwd_confirmation are the same. If not the pwd field is filled with stars! I want it to be blank too! Rob
on 2007-12-14 17:23
common thing, and you're right, it's the password content. two ways to solve that: 1) in controller set password to nil (and make sure later, that this does not lead to empty passwords being stored) 2) create an additional attr_accessor :password_input (like password_confirmation) and make sure, that it's stored in db before_save would be a good place to do that
on 2007-12-14 18:13
thx thorsten i just found the exact same articel...i just didn't get to set the password in the controller to nil. i set the :value => "" it works fine too. How would i do that out of the controller?