When an error is identified, the script inserts a list of error messages into the DOM and moves focus to them. Thank you! That will help you find the problem johnyboy Is there a parameter which can be added to the validation code for alphanumeric or alnum which would include the ‘-‘ (hyphen) character. How you design your form plays a role in how easy you will be able to identify your form elements.
Help? Showing all the form validation errors together in a message box If you want to show all the error messages together, then just call the EnableMsgsTogether() function as shown below. I have used a more compact loop method of checking the input boxes for an entry than your original script, but it does the same thing. Now that you have some basic understanding of regular expressions, let's continue with the code: We now need to compare the submitted email address against the "validemail" pattern that we defined