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 trialweb pad
4,483 PointsHi, will it matter if I write the elements in different order? I tried to preview it and it turned okay. Just want to..
Nick in the video just put the label tag right after the input tag side by side. The code looks very long for me. I tried to put the label tag in a different line for ease of coding and viewing, and it turned okay when I previewed it. But is it still correct though? In terms of proper semantics?
<form action="" method="POST"> <h1>Sign up Form</h1> <fieldset> <legend><span class="number">1</span>Your basic info</legend> <label for="name">Name</label> <input type="text" id="name" name="user_name">
<label for="mail">Email</label>
<input type="email" id="mail" name="user_email">
<label for="password">Password</label>
<input type="password" id="password" name="user_password">
<label>Age:</label>
<input type="radio" id="under13" value="under13" name="userage">
<label for="under13" class="light"> Under 13</label> <br>
<input type="radio" id="over13" value="over13" name="userage">
<label for="over13" class="light">Over 13</label>
</fieldset>
2 Answers
Steven Parker
231,268 PointsIn most cases, blank lines in HTML code have no effect on the rendered page, so you can use them as you like to make the code more readable.
The same is true of spacing used to illustrate nesting levels.
web pad
4,483 PointsThank you.