├── index.html ├── styles.css └── validation.js /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | RegEx Form 6 | 7 | 8 | 9 |

New User Signup

10 |
11 | 12 | 13 |

Username must be and contain 5 - 12 characters

14 | 15 | 16 |

Email must be a valid address, e.g. me@mydomain.com

17 | 18 | 19 |

Password must alphanumeric (@, _ and - are also allowed) and be 8 - 20 characters

20 | 21 | 22 |

Telephone must be a valid UK telephone number (11 digits)

23 | 24 | 25 |

Slug must contain only lowercase letters, numbers and hyphens and be 8 - 20 characters

26 | 27 |
28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /styles.css: -------------------------------------------------------------------------------- 1 | body{ 2 | font-family: arial; 3 | color: #333; 4 | } 5 | h1{ 6 | font-weight: normal; 7 | margin: 20px auto; 8 | text-align: center; 9 | } 10 | form{ 11 | width: 500px; 12 | margin: 20px auto; 13 | } 14 | input{ 15 | display: block; 16 | padding: 8px 16px; 17 | font-size: 2em; 18 | margin: 10px auto; 19 | width: 100%; 20 | box-sizing: border-box; 21 | border-radius: 10px; 22 | border: 3px solid #ccc; 23 | outline: none !important; 24 | } 25 | -------------------------------------------------------------------------------- /validation.js: -------------------------------------------------------------------------------- 1 | // validation script here 2 | --------------------------------------------------------------------------------