Command Palette

Search for a command to run...

Hectal
Phase 7: Accessibility and Quality
HTML · Exercise 2 of 6 PreviousNext
Beginner

Label every field

This contact form uses placeholders instead of labels, and its radio buttons have no question. Make it accessible:

1. Give the name and email fields visible <label> elements connected to them (keep the placeholders if you like, but they're not labels).

2. Give each radio button its own label (Email and Phone).

3. Group the radio buttons in a <fieldset> with a <legend> that asks the question, for example How should we contact you?.

What Check tests

  1. The name field has a label with text
  2. The email field has a label with text
  3. The labels are visible (not hidden)
  4. Each radio button has its own label
  5. The radios are in a fieldset with a legend that asks the question

Stuck? One hint at a time

The solution unlocks after your first Check. Try first: that is where the learning happens.

Runs in your browser. Your code is saved here.

Your page

Press Run to see the page.

Console

Nothing logged yet.