|
1 | | -<!DOCTYPE html> |
| 1 | +<!doctype html> |
2 | 2 | <html lang="en"> |
3 | 3 | <head> |
4 | 4 | <meta charset="utf-8" /> |
5 | 5 | <meta http-equiv="X-UA-Compatible" content="IE=edge" /> |
6 | 6 | <title>T-shirt Order Form</title> |
7 | | - <meta name="description" content="" /> |
| 7 | + <meta |
| 8 | + name="description" |
| 9 | + content="T-shirt order form for customers to place orders" |
| 10 | + /> |
8 | 11 | <meta name="viewport" content="width=device-width, initial-scale=1" /> |
9 | | - <link rel="stylesheet" href="style.css"> |
| 12 | + <link rel="stylesheet" href="style.css" /> |
10 | 13 | </head> |
11 | 14 | <body> |
12 | | - <main> |
13 | | - |
14 | | - <form method="get" class="container"> |
15 | | - <!-- Requirements: |
| 15 | + <main> |
| 16 | + <form method="get" class="container"> |
| 17 | + <!-- Requirements: |
16 | 18 | - What is the customer's name? I must collect this data and ensure it contains at least two non-space characters. |
17 | 19 | - What is the customer's email? I must make sure the email is valid. Email addresses follow a consistent pattern. |
18 | 20 | - What colour should this T-shirt be? I must provide 3 options and to ensure they do not choose other colours. |
19 | 21 | - What size does the customer want? I must provide the following 6 options: XS, S, M, L, XL, XXL and to ensure they do not choose other sizes. |
20 | 22 | --> |
21 | | - <header> |
22 | | - <h1>T-shirt Order Form</h1> |
23 | | - </header> |
| 23 | + <header> |
| 24 | + <h1>T-shirt Order Form</h1> |
| 25 | + </header> |
24 | 26 |
|
25 | | - <hr> |
26 | | - <label for="name">Full Name</label> |
27 | | - <input id="name" name="name" type="text" minlength="2" placeholder="First Name Surname" pattern="[A-Za-z ]{2,}" required> |
| 27 | + <hr /> |
| 28 | + <label for="name">Full Name</label> |
| 29 | + <input |
| 30 | + id="name" |
| 31 | + name="name" |
| 32 | + type="text" |
| 33 | + minlength="2" |
| 34 | + placeholder="First Name Surname" |
| 35 | + pattern="[\p{L} ]{2,}" |
| 36 | + required |
| 37 | + /> |
28 | 38 |
|
29 | | - <hr> |
30 | | - <label for="email">Email</label> |
31 | | - <input id="email" name="email" type="email" pattern="[A-Za-z0-9._%+\-]+@[A-Za-z0-9.\-]+\.[A-Za-z]{2,}$" |
32 | | - placeholder="Your email" required> |
| 39 | + <hr /> |
| 40 | + <label for="email">Email</label> |
| 41 | + <input |
| 42 | + id="email" |
| 43 | + name="email" |
| 44 | + type="email" |
| 45 | + pattern="[A-Za-z0-9._%+\-]+@[A-Za-z0-9.\-]+\.[A-Za-z]{2,}$" |
| 46 | + placeholder="Your email" |
| 47 | + required |
| 48 | + /> |
33 | 49 |
|
34 | | - <hr> |
35 | | - <label for="colour">T-shirt Colour:</label> |
36 | | - <select name="colour" id="colour" required> |
37 | | - <option value="">Choose a Colour</option> |
38 | | - <option value="Red">Red</option> |
39 | | - <option value="Blue">Blue</option> |
40 | | - <option value="Yellow">Yellow</option> |
41 | | - </select> |
| 50 | + <hr /> |
| 51 | + <label for="colour">T-shirt Colour:</label> |
| 52 | + <select name="colour" id="colour" required> |
| 53 | + <option value="">Choose a Colour</option> |
| 54 | + <option value="Red">Red</option> |
| 55 | + <option value="Blue">Blue</option> |
| 56 | + <option value="Yellow">Yellow</option> |
| 57 | + </select> |
42 | 58 |
|
43 | | - <hr> |
44 | | - <label for="Size">T-shirt Size:</label> |
45 | | - <select name="size" id="Size" required> |
46 | | - <option value="">Choose a Size</option> |
47 | | - <option value="XS">XS</option> |
48 | | - <option value="S">S</option> |
49 | | - <option value="M">M</option> |
50 | | - <option value="L">L</option> |
51 | | - <option value="XL">XL</option> |
52 | | - <option value="XXL">XXL</option> |
53 | | - </select> |
| 59 | + <hr /> |
| 60 | + <label for="Size">T-shirt Size:</label> |
| 61 | + <select name="size" id="Size" required> |
| 62 | + <option value="">Choose a Size</option> |
| 63 | + <option value="XS">XS</option> |
| 64 | + <option value="S">S</option> |
| 65 | + <option value="M">M</option> |
| 66 | + <option value="L">L</option> |
| 67 | + <option value="XL">XL</option> |
| 68 | + <option value="XXL">XXL</option> |
| 69 | + </select> |
54 | 70 |
|
55 | | - <hr> |
56 | | - <button type="submit">Submit</button> |
| 71 | + <hr /> |
| 72 | + <button type="submit">Submit</button> |
57 | 73 |
|
58 | 74 | <!-- write your html here--> |
59 | 75 | <!-- |
60 | 76 | try writing out the requirements first as comments |
61 | 77 | this will also help you fill in your PR message later--> |
62 | 78 | </form> |
63 | | - </main> |
| 79 | + </main> |
64 | 80 | <footer> |
65 | 81 | <!-- change to your name--> |
66 | 82 | <p>By Lesya Lyaisyan</p> |
|
0 commit comments