I have a form attribute like so:
onsubmit="return valMyForm(this);"
And a jQuery function like so:
function valMyForm(f) {
$(f,"input").each(function() {
if($(this).length < 1) {
alert("All Fields Required.");
return false;
}
else
return false;
});
}
The form still submits even if I remove all of the code and just put return false;
elseisn't necessary. ;-)