One thing you could do, which is kind of a hack, is make a 'work done' global var in your script. The first thing the two functions do is check that var to make sure the other one is didn't already fire. If the coast is clear, they set that var as part of their work. Would that work?
You could also look around for a script that disables the enter key (I've seen them before), so the form doesn't submit if the user hits enter, but I'd guess that's a bad option. > -----Original Message----- > From: Scott Weikert [mailto:[EMAIL PROTECTED] > Sent: Tuesday, December 05, 2006 12:54 PM > To: CF-Talk > Subject: Re: combining two types of JS-related validation > > Munson, Jacob wrote: > > I'm having trouble following your logic, but I'd think if > you have one > > function in the onBlur of an input, and the other in the > onSubmit of the > > form tag, it should keep them separate. What's causing them both to > > fire? > > > They both fire in the event of someone making a change to the email > address, and hitting 'return', submitting the form. If the qForms > validation (triggered by the submit) finds a problem, it throws up an > alert - causing the 'email' field to blur, which then triggers the > Ajaxified code. > > As best I can tell, I can't simply change the 'submit' button to a > 'button' button and throw a 'submit()' call in the onClick for that > button, as qForms seems to rely on a normal form submittal as > opposed to > the form being submitted via a JS call. > > I had a coworker testing this, and depending on what he did, it would > throw him into an infinite loop of alerts, which is the main > reason I'm > trying to get this resolved. "EMF <idahopower.com>" made the following annotations. ------------------------------------------------------------------------------ This transmission may contain information that is privileged, confidential and/or exempt from disclosure under applicable law. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, or use of the information contained herein (including any reliance thereon) is STRICTLY PROHIBITED. If you received this transmission in error, please immediately contact the sender and destroy the material in its entirety, whether in electronic or hard copy format. Thank you. ============================================================================== ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Create robust enterprise, web RIAs. Upgrade & integrate Adobe Coldfusion MX7 with Flex 2 http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:262949 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

