Works fine for me in Firefox But you have this line at the start of the validation function that I assume can only be for testing purposes: alert(document.getElementById('Email').value);
On Apr 22, 10:57 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Hi, > > When I submit the contact form > > http://elearningrd.info/jrl/contact.php > > I would like to validate the email address and possibly check non- > empty values for the other fields. I'm using this code to try and > check things upon form submission: > > $(document).ready(function() { > $('#msgForm').submit(function() { > var email = $('#Email').val(); > if (!validateForm(email)) { > alert("Invalid email format."); > return false; > } > return true; > }); > }); > > but the form validation doesn't seem to be invoked. Any ideas why? > > Thanks, - Dave