Is there a way of generating client-side javascript validations, maybe Unobtrusive Javascript or something like that? Thanks -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
ljredpath-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
2006-Sep-15 10:54 UTC
Re: Javascript validations
Hi Dmitry, inspired by your post I''ve put together a small Rails plugin that lets you create unobtrusive AJAX validations that hook into your model validations, making things nice and dry. If it finds an error when you tab out of a field, it adds an "error" class to the field and inserts a list of validation errors. It can also take a callback which it sends the errors to in JSON format for advanced handling. There is still some cleaning up to be done but I hope to have something out next week. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
unknown wrote:> Hi Dmitry, inspired by your post I''ve put together a small Rails plugin > that lets you create unobtrusive AJAX validations that hook into your > model validations, making things nice and dry. If it finds an error > when you tab out of a field, it adds an "error" class to the field and > inserts a list of validation errors. It can also take a callback which > it sends the errors to in JSON format for advanced handling. > > There is still some cleaning up to be done but I hope to have something > out next week.That''s great, I''ll try your plugin once it is ready -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
unknown wrote:> Hi Dmitry, inspired by your post I''ve put together a small Rails plugin > that lets you create unobtrusive AJAX validations that hook into your > model validations, making things nice and dry. If it finds an error > when you tab out of a field, it adds an "error" class to the field and > inserts a list of validation errors. It can also take a callback which > it sends the errors to in JSON format for advanced handling. > > There is still some cleaning up to be done but I hope to have something > out next week.This sounds a lot like what I''ve done for my company a while back. I described my approach in detail in "Ajax validation on Rails", which is available at http://www.bigsmoke.us/ajax-validation-on-rails/ if you''re interested. I never thought of turning it into a plugin, though. I''m very curious to see what you''ll make of it. It sounds like a great idea! -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
On Monday 04 September 2006 07:48, Dmitry Hazin wrote:> Is there a way of generating client-side javascript validations, > maybe Unobtrusive Javascript or something like that?Yes: http://www.agilewebdevelopment.com/plugins/client_side_validation http://www.agilewebdevelopment.com/plugins/validation_reflection Michael -- Michael Schuerig mailto:michael-q5aiKMLteq4b1SvskN2V4Q@public.gmane.org http://www.schuerig.de/michael/ --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---