> There may be other reasons you may want to > call a function when everything is OK
Can you give some examples of what you're thinking about? > or there is an error (maybe > highlight /animate the fields with errors?). I'm placing individual error messages above each field when there is an error... do you think I should do something more? Thanks for the feedback... Rick -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sam Collett Sent: Monday, March 12, 2007 3:05 AM To: jQuery Discussion. Subject: Re: [jQuery] Validation help with Date Selector On 11/03/07, Jörn Zaefferer <[EMAIL PROTECTED]> wrote: > Rick Faircloth schrieb: > > onInvalid: function(form) { > > $(form).find("[EMAIL PROTECTED]").attr("disabled", "disabled"); > > }, > > onValid: function(form) { > > $(form).find("[EMAIL PROTECTED]").attr("disabled", ""); > > } > > > > > > > > That looks good to me! Hopefully that will work. I'm using Jorn's plug-in > > in debug mode, which is supposed to prevent submission whether the > > form fields are correct or not. However, since I'm using other script which > > works in an Ajax manner to submit the entries to another page, I think > > that's > > interfering somewhat with Jorn's plug-in and its control over the process. > > > > I'll tinker around with your methods above and see what happens. > > > > Hopefully, Jorn will show up and provide us some assistance, too... > > > See the other thread. Just write your own submitHandler, that way you > don't need to disable anything. > > -- > Jörn Zaefferer > > http://bassistance.de While you can do that, making the button disabled is a good visual indication (in addition to the error message(s)) and prevents the click in the first place. There may be other reasons you may want to call a function when everything is OK, or there is an error (maybe highlight /animate the fields with errors?). _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/