What am i doing wrong? I changed the radio button, but still it is not processing. Why?

Tell us what’s happening:
Describe your issue in detail here.

  **Your code so far**

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

<a href="#"><img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" 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="https://www.freecatphotoapp.com/submit-cat-photo">
<input id="indoor" type="indoor" type="indoor" name="indoor-outdoor"> Indoor</label>
<input id="outdoor" value="outdoor" type="outdoor" name="indoor-outdoor"> Outdoor</label>
    <input id="loving" value="loving" type="loving" name="personality"> Loving</label>
    <input id="lazy" value="lazy" type="lazy" name="personality"> Lazy</label>
<input id="energetic" value="energetic" type="energetic" name="personality"> Energetic</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/94.0.4606.81 Safari/537.36

Challenge: Use the value attribute with Radio Buttons and Checkboxes

Link to the challenge:

Hi @ankuaakanksha21 !

I would reset the lesson because you have a few errors.

This is a value attribute


Take a look at the example they gave you to see how the value attribute works with the label

<label for="outdoor">
  <input id="outdoor" value="outdoor" type="radio" name="indoor-outdoor">Outdoor

You see this part of the example where they are using the value attribute


Your task is to add a value attribute to each of the radio buttons and checkboxes

Hope that helps!

This is not valid html

You need to remove all of that stuff

syntax for label tag is

< label> your lable </ label>

i removed it,but still it is not working

What is your latest code?
Can you post it here?

When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (’).

Hello, first this is your task. " Give each of the existing radio and checkbox inputs the value attribute. Do not create any new radio or checkbox elements. Use the input label text, in lowercase, as the value for the attribute."

So first error: <input id="indoor" type="indoor" type="indoor" name="indoor-outdoor"> Indoor</label>
The programs ask your to just add the value attribute and give it the input name id
So this is how you should do it :<input id="indoor" type="radio" value="indoor" name="indoor-outdoor"> Indoor</label>
Second error is that you are using the <label> wrong:
This is how it should be:<label for="example"></label>
Hope I helped you.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.