Why isn't this validating?

Tell us what’s happening:
It keeps telling me that each of my radio button elements needs to be nested in its own label element. I’m pretty sure I’ve done that. I have watched the video a few times and I cannot find anything wrong with it. Please help!

Your code so far

<p>Click here to view more <a href="#">cat photos</a>.</p>

<a href="#"><img src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying on its back."></a>

<p>Things cats love:</p>
  <li>cat nip</li>
  <li>laser pointers</li>
<p>Top 3 things cats hate:</p>
  <li>flea treatment</li>
  <li>other cats</li>
<form action="/submit-cat-photo">
<input id="indoor" type="radio" name="indoor-outdoor">
<label for="indoor">Indoor</label>
<input id="outdoor" type="radio" name="indoor-outdoor">
<label for="outdoor">Outdoor</label>
  <input type="text" placeholder="cat photo URL" required>
  <button type="submit">Submit</button>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.130 Safari/537.36.

Challenge: Create a Set of Radio Buttons

Link to the challenge:

Your input button isn’t nesting inside the label (i.e. ).

Hope this helps!

This is an example of a nesting

<parent element>
  <nested element> stuff </nested element>
</parent element>

None of your radio buttons are nested in labels. They are all before labels.

1 Like