Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML HTML Forms Choosing Options Create Radio Buttons

javier graterol
javier graterol
6,056 Points

label not working

they ask for this in the challenge but it doesnt gets trough...

They say you need to put a <label> right before the first radio buttons that states Shirt Size

    <label for="shirt_size">Shirt Size</label>
    <input type="radio" id="small" value="small" name="shirt_size">
    <input type="radio" id="medium" value="medium" name="shirt_size">
    <input type="radio" id="large" value="large" name="shirt_size">

5 Answers

Hi Javier,

Are you sure that you've put all of that after the closing select, </select> and before the <button>?

Your html passes for me if I take out the for attribute.

Erik McClintock
Erik McClintock
45,783 Points

Javier,

In that part of the challenge, they ask you to create a label but to not associate it with anything: remove your "for" in the label and you should pass onto the next step of the challenge!

Erik

javier graterol
javier graterol
6,056 Points

This is the hole code, i dont get it. and if i dont finish this one i can start the other tracks...

<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>HTML Forms</title> </head> <body> <form action="index.html" method="post"> <h1>Shirt Order Form</h1> <select id="color" name="shirt_color"> </select> <label>Shirt Color:</label> <option value="red">Red</option> <option value="yellow">Yellow</option> <option value="purple">Purple</option> <option value="blue">Blue</option> <option value="green">Green</option> <option value="orange">Orange</option> <button type="submit">Place Order</button> </form> </body> </html>

javier graterol
javier graterol
6,056 Points

i know, but even when i take off the for, the problems persists...

javier graterol
javier graterol
6,056 Points

sorry guys, that was it, i was putting it before the </select> element. Thanks!