[thelist] with Enter, onBlur is preceded by onSubmit

Ken Kogler ken.kogler at cph.org
Fri Jun 14 10:52:01 CDT 2002


> Not to break up the fun, but per chance does anyone
> have an answer to my question? Just in case you don't
> recall, it was "why is IE executing the onBlur event
> AFTER the onSubmit event when the form is submitted
> with the Enter key, and how do I fix it?"

AFAIK, pressing the Enter key does not take the focus away from the current
element until it submits the form. If your onBlur event is in "fieldA", and
the focus is there when I press Enter, the form will submit (which sets of
the onSubmit) then the browser will move focus to the submit button when it
realizes what happened, which triggers the onBlur.

This ain't scientific fact - just my observations. I could be waaaaaay off
base here.

-Ken




More information about the thelist mailing list