Closing tags need help

Tell us what’s happening:
keeps saying theres a problem with the closing tags for label and im not sure how to fix it

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="https://freecatphotoapp.com/submit-cat-photo">
  <label for="indoor"><input id="indoor" type="radio" name="indoor-outdoor"> Indoor<label for="indoor"></label>
  <label for="outdoor"><input id="outdoor" type="radio" name="indoor-outdoor"> Outdoor<label for="outdoor"></label>
<label for="loving"><input id="loving" type="checkbox" name="personality"> Loving 
</label>
<label for="mean"><input id="loving" type="checkbox" name="personality"> mean 
</label>
<label for="sleepy"><input id="loving" type="checkbox" name="personality"> sleepy 
</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 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.111 Safari/537.36.

Challenge: Create a Set of Checkboxes

Link to the challenge:

Syntax error in above block of code, in HTML elements have an opening tag and closing tag. Just watch with a close eye, you will get it.

If you noticed below the form tag, there are two opening tags of label yet one closing tag.
You should delete the second opening tag because it’s a duplicate of the first one.

1 Like

If you’re using VSCode, it will show where is the syntax error; it’ll be much easier to fix

thank you this was very helpful