I have this:
$("#contact-frm-2").bind("jqv.form.result", function(event , errorFound){
if(!errorFound){
alert('go!');
event.preventDefault();
return false;
}
});
It supposed to validate the form for errors and when there is no error on the form, alert "Go!" without submitting.
I am using the jquery.ValidationEngine.js you can find at http://www.position-absolute.com/articles/jquery-form-validator-because-form-validation-is-a-mess/
I am sure
event.preventDefault();
return false;
is supposed to prevent the form from submitting but it is still submitting. Can someone tell me what I am missing?
The “onsubmit” JavaScript event will handle this for you.
jQuery:
Pure JS: