-
Notifications
You must be signed in to change notification settings - Fork 0
/
form exercise.html
65 lines (56 loc) · 2.06 KB
/
form exercise.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<!DOCTYPE html>
<html>
<head>
<!-- Excercise on creating forms with different input types -->
<meta charset="utf-8">
<title>Registration Form</title>
</head>
<body>
<h1>Register</h1>
<form>
<label for="FirstName">First Name:</label>
<input id="FirstName" type="text" placeholder="John" name="FirstName"required>
<label for="LastName">Last Name:</label>
<input id="LastName" type="text" placeholder="Smith" name="LastName"required>
</p>
<!-- Could also use a div here -->
<label for="Male">Male</label>
<input id="Male" type="Radio" name="sex" value="Male"/>
<label for="Female">Female</label>
<input id="Female" type="Radio" name="sex" value="Female"/>
<label for="Other">Other</label>
<input id="Other" type="Radio" name="sex" value="Other"/>
</p>
<label for="Email">Email:</label>
<input id="Email" type="email" name="email" placeholder="your email" required />
<label for="Password">Password:</label>
<input id="Password" type="password" name="password" placeholder="your password" required=">10" required="<5"/>
</p>
<label for="Birthday">Birthday:</label>
<select name="month" placeholder="Month">
<option value="Jan">January</option>
<option value="Feb">February</option>
</select>
<select name="Day" placeholder="Day">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
</select>
<select name="year" placeholder="year">
<option value="2000">2000</option>
<option value="2001">2001</option>
<option value="2001">2002</option>
<option value="2001">2003</option>
<option value="2001">2004</option>
<option value="2001">2005</option>
</select>
</p>
<label for="consent">I agree to the terms and conditions</label>
<input id="consent" type="radio" required />
</p>
<button>Submit</button>
</form>
</body>
</html>