Could you possibly have a look at the attached file and see if there's something I'm missing. The server side validation works fine. But the javascript doesn't seem to execute. I've tried copying the email form out to a separate php file with the javascript in the head and that works fine, so there must be something else on the page thats preventing it from working.