Javascript form validation events
Posted
by user307922
on Stack Overflow
See other posts from Stack Overflow
or by user307922
Published on 2010-06-03T14:50:46Z
Indexed on
2010/06/03
14:54 UTC
Read the original article
Hit count: 220
Hi All,
I am making a small form for a php app and had a question regarding javascript validation.
What is the best event to run the javascript validation on the input value? Is it the "focusout" event?
I used "focusout" to originally but it creates problems when the user hits enter while they are still focused on any particular field in the form.
Should I run the js validation when the user clicks submit?
Just looking for some advice.
Thanks!
Chuck
© Stack Overflow or respective owner