I m not able to find what wrong is in there when ever i click on run the test it shows "// running tests Each of your two radio button elements should be nested in its own label element. // tests completed"

Tell us what’s happening:

Your code so far


<h2>CatPhotoApp</h2>
<main>
<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>
<ul>
  <li>cat nip</li>
  <li>laser pointers</li>
  <li>lasagna</li>
</ul>
<p>Top 3 things cats hate:</p>
<ol>
  <li>flea treatment</li>
  <li>thunder</li>
  <li>other cats</li>
</ol>
<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>
</form>
</main>

Your browser information:

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

Challenge: Create a Set of Radio Buttons

Link to the challenge:

Hi @xeacid,

I run your solution and below is the error you get:

image

Here is an example of how to nest radio buttons:

image

Have a look at your code again, it is not quite the same but not far off :slight_smile:

I hope this helps.

THIS is already written there but i m not able to understand what i should do.

Hi,

The task asks you to nest two radio buttons in their own label elements . Your code does not do it as per example, hence why I pointed you back to the example.

Maybe reset your code and try again :slight_smile:

1 Like

you have the elements one after the other, not one inside the other as required

2 Likes

you put your label after input not with input
put your input inside label tag