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 trialImmanuel Jaeggi
5,164 PointsMy lables don`t focus on the corresponding fields when clicked on.
<lable for="name">Name:</lable> <input type="text" id="name" name="user_name">
The above is an example of what I did and it still does not focus on the corresponding field when I click it. Any ideas? Tx
2 Answers
Steven Parker
231,236 PointsIs just a spelling issue. You wrote "lable" instead of "label" (twice).
It's normal for HTML tags that are not recognized to be simply ignored by the browser. But the text is still rendered (as a plain text node).
Browser's won't reveal this type of error but you can run the page through an HTML validator. The "official" online validator is available at validator.w3.org.
Immanuel Jaeggi
5,164 PointsNooooo! Txs! Would you know why I still was able to see the labels name, email, etc although the element was spelt wrong? It seems to me that it shouldn't have rendered the form with all the labels. Then I would have known where to check for errors.
Jack Weldon
1,708 Pointsit's the closing tag that is misspelt, meaning that the attribute won't load properly (In this case the focus). Since the tag is open, it's taking everything after the attribute to be the focus destination. Correct the spelling in the closing tag and give it another shot.
Steven Parker
231,236 PointsI expanded my answer to explain the text rendering.
Immanuel Jaeggi
5,164 PointsImmanuel Jaeggi
5,164 PointsThanks a lot for your help.