Use the value attribute with Radio Buttons and Checkboxes Help!

Tell us what’s happening:

Can someone give me a hand with this I’ve been stuck on this for a few days now

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>
  <label for="Outdoor"><input id="Outdoor" type="radio" name="indoor-outdoor"> Outdoor</label><br>
  <label for="Loving"><input id="Loving" type="checkbox" name="personality"> Loving</label>
  <label for="Lazy"><input id="Lazy" type="checkbox" name="personality"> Lazy</label>
  <label for="Energetic"><input id="Energetic" type="checkbox" name="personality"> Energetic</label><br>
  <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/87.0.4280.88 Safari/537.36.

Challenge: Use the value attribute with Radio Buttons and Checkboxes

Link to the challenge:

where are the value attributes?

1 Like

[quote=“pl3x, post:1, topic:434328”]
@ilenia is true.
you should add value attributes like below.

<form action="https://freecatphotoapp.com/submit-cat-photo">
  <label for="Indoor"><input id="Indoor" value = "indoor" type="radio" name="indoor-outdoor"> Indoor</label>
  <label for="Outdoor"><input id="Outdoor" value = "outdoor" type="radio" name="indoor-outdoor"> Outdoor</label><br>
  <label for="Loving"><input id="Loving" value = "loving" type="checkbox" name="personality"> Loving</label>
  <label for="Lazy"><input id="Lazy" value = "lazy" type="checkbox" name="personality"> Lazy</label>
  <label for="Energetic"><input id="Energetic" value = "energetic" type="checkbox" name="personality"> Energetic</label><br>
  <input type="text" placeholder="cat photo URL" required>
  <button type="submit">Submit</button>
</form>

I hope my code will help you, @pl3x

It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge.

We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.

May be it’s true. thank you for your suggestion, @ilenia.

Thank you so much Jack I been racking my brain on this one for a few days I owe you one big time again thank you so much for helping me out.