Medha Kulkarni
2006-Jun-18 12:04 UTC
[Rails] plugings for date validations, email address validation & url validations in rails
Hi all, Is there any standard plugin available for date validations, email address validation & url validations in rails? Thanks in advance, Medha. -- If not you then who..... If not now then when...... ----------------------------------------------------- With Best Regards, Medha. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060618/c80964ab/attachment.html
Bojan Mihelac
2006-Jun-18 14:23 UTC
[Rails] plugings for date validations, email address validation & url validations in rails
Medha Kulkarni wrote:> > Hi all, > > Is there any standard plugin available for date validations, email > address validation & url validations in rails? > > Thanks in advance, > Medha. > > -- > If not you then who..... > If not now then when...... > ----------------------------------------------------- > With Best Regards, > Medha. > > > ------------------------------------------------------------------------ > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/railsE-mail: validates_format_of :email, :with => /^([^@\s]+)@((?:[-a-z0-9]+\.)+[a-z]{2,})$/i For URL, find regex (I am sure there are plenty on internet if you do not know to writ one) and use it same way. hope it helps, Bojan -- Bojan Mihelac Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com -> tools, scripts, tricks from our code lab: http://source.mihelac.org