
This is a short and simple form validation code that uses regular expression to compare the user input to the pattern rule defined by a regular expression string. form validation code will either use "if" statments, or regular expressions to validate that the user entered the currect information . The main difference between this code and others , is that the regular expression pattern, and the error message, both are located inside the html control tag and not in the function itself.
|