Regular Expressions For Diferent Field Vaalidation ASP code project download
| Field | Expression | Format Samples | Description |
|---|---|---|---|
| Name | ^[a-zA-Z''-'s]{1,40}$ | John Doe O’Dell |
Validates a name. Allows up to 40 uppercase and lowercase characters and a few special characters that are common to some names. You can modify this list. |
| Social Security Number | ^d{3}-d{2}-d{4}$ | 111-11-1111 | Validates the format, type, and length of the supplied input field. The input must consist of 3 numeric characters followed by a dash, then 2 numeric characters followed by a dash, and then 4 numeric characters. |
| Phone Number | ^[01]?[- .]?(([2-9]d{2})|[2-9]d{2})[- .]?d{3}[- .]?d{4}$ | (425) 555-0123 425-555-0123 425 555 0123 1-425-555 |