Create a Set of Radio Buttons 1111

Tell us what’s happening:

" Give your radio buttons the name attribute of indoor-outdoor ."
" Each of your two radio button elements should be nested in its own label element."
As u can see i did but its not working !!

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 type="text" placeholder="cat photo URL" required>
    <button type="submit">Submit</button>
  
    <input id="indoor" type="radio" of ="indoor-outdoor">
  <label id="indoor"> indoor </label>
    <input id="outdoor"type="radio" name="indoor-outdoor">
 <label for "outdor"> outdoor </label>
</main>

Your browser information:

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

Link to the challenge:
https://learn.freecodecamp.org/responsive-web-design/basic-html-and-html5/create-a-set-of-radio-buttons

This is your label, it doesn’t have an other element nested inside, you should nest your input inside the label element

You also have a few typos, but this is the main issue

Thanks for your reply I nested the unput inside the label element and and i passed that test but it still says that i have to " Give your radio buttons the name attribute of indoor-outdoor ."
i don’t know whats wrong in that

Only one of the inputs have this

Id should be unique (you need it on the label or on the input? You can’t on both)

Missing the = here

This is not an attribute you should use

Maybe something else…

If you fix this and there is something else post your code please

heres the code still does not work i fixed a lot (sorry for bothernig you )

you can’t have the same id on two different elements, id needs to be unique. where are you asked to put it?

I don’ think I’m asked to put it actually ! :sweat_smile::sweat_smile: and I’m not having the same id in two different elements i think

heyy i could finallyy rin the test . there was a space missing … <3 thakns for ur supporttt

you have the same id on the label and the input, it is bad practice

if you want more detailed help you should really not post a screenshot but your actual code

haaaaaaaaahh got you … sry I’m a begginer soo yeahh :stuck_out_tongue: