[Rails] Extra Fields?
Tobias Luetke
tobias.luetke at gmail.com
Thu Nov 11 20:40:57 GMT 2004
I added extra fields called password_confirmation and
email_confirmation to my signup form and added this to the controller
:
@newuser.errors.add("password", "does not match") unless
@newuser.password == @params['password_confirmation']
@newuser.errors.add("email", "does not match") unless
@newuser.email == @params['email_confirmation']
On Thu, 11 Nov 2004 12:35:34 -0800, Russ Smith <russ at igeanetwork.com> wrote:
> I'm wondering how you would go about putting a "confirm password" field
> into a form and not have it inserted into the database. An example
> would be on the Basecamp sign up form. And also on that page is an
> "accept terms" checkbox. I guess I want to know how do you run these
> fields through validation (model or controller) and not have them
> automatically entered into the database.
>
> Russ
>
> _______________________________________________
> Rails mailing list
> Rails at lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
--
Tobi
http://blog.leetsoft.com
More information about the Rails
mailing list