Hi, I am wondering how people will validate the size of a password field.. when I use validate_size_of it always pass because the encrypted password is almost longer than 8 characters.. so how does people force users to enter a 8 char password? 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Wite an javascript function which would force the user to enter atleast 8 charachters.. On Aug 29, 6:21 am, "ReK2-..-..-...---->" <r...-zTjyZANo7oz3ktU1ABlop6HonnlKzd3f@public.gmane.org> wrote:> Hi, I am wondering how people will validate the size of a password field.. > when I use validate_size_of it always pass because the encrypted > password is almost longer than 8 characters.. > so how does people force users to enter a 8 char password? > > 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Hi, you''re actually validating the input to your application instead of the representation in your database. You''re correct in saying the encrypted password is longer than the input entered by the user. Next, I would only check the length of the password in the following scenarios: o user registration/creation o user password change/reset Otherwise, you shouldn''t be checking the length of the password. Good luck, -Conrad On Thu, Aug 28, 2008 at 6:21 PM, ReK2-..-..-...----> < rek2-zTjyZANo7oz3ktU1ABlop6HonnlKzd3f@public.gmane.org> wrote:> > Hi, I am wondering how people will validate the size of a password field.. > when I use validate_size_of it always pass because the encrypted > password is almost longer than 8 characters.. > so how does people force users to enter a 8 char password? > > 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---