Skip to content

Commit 2bb47a3

Browse files
committed
add radio buttons for colour and a dropdown selector for size
1 parent c00ddfc commit 2bb47a3

1 file changed

Lines changed: 32 additions & 0 deletions

File tree

Form-Controls/index.html

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ <h1>Product Pick</h1>
2525
pattern=".*\S.*\S.*"
2626
title="Please enter your name, or at least two non-space characters."
2727
/>
28+
<br />
2829
<!-- Customer email: required, valid email format -->
2930
<label for="customer-email">Email</label>
3031
<input
@@ -33,8 +34,39 @@ <h1>Product Pick</h1>
3334
type="email"
3435
required
3536
/>
37+
<br />
3638
<!-- T-shirt colour: required, 3 choices -->
39+
<fieldset>
40+
<legend>T-shirt colour</legend>
41+
42+
<label>
43+
<input type="radio" name="colour" value="black" required />
44+
Black
45+
</label>
46+
47+
<label>
48+
<input type="radio" name="colour" value="white" />
49+
White
50+
</label>
51+
52+
<label>
53+
<input type="radio" name="colour" value="blue" />
54+
Blue
55+
</label>
56+
</fieldset>
3757
<!-- T-shirt size: required, XS, S, M, L, XL, XXL -->
58+
<br />
59+
<label for="tshirt-size">T-shirt size</label>
60+
<select id="tshirt-size" name="tshirt-size" required>
61+
<option value="">Select size</option>
62+
<option value="xs">XS</option>
63+
<option value="s">S</option>
64+
<option value="m">M</option>
65+
<option value="l">L</option>
66+
<option value="xl">XL</option>
67+
<option value="xxl">XXL</option>
68+
</select>
69+
<br
3870
<!-- Submit button -->
3971
<button type="submit">Order T-shirt</button>
4072
</form>

0 commit comments

Comments
 (0)