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 trialChristina Araujo
Full Stack JavaScript Techdegree Student 4,819 Points"You need to set the 'href' attribute of the second <a> element to 'pies.html'." So I am stuck here.
So I am stuck here are can't figure out what I did wrong in this situation. Could someone give me a hint?
Thank you
<!DOCTYPE html>
<html>
<head>
<title>Lists and Links</title>
</head>
<body>
<ul>
<a href="cakes.html"> <li>Cakes</li></a>
<a href="pies.html"> <li>Pies</li></a>
<a href="candy.html"> <li>Candy</li></a>
</ul>
</body>
</html>
3 Answers
Patrik Horváth
11,110 Pointshi, simple your code is not VALID HTML its somekind of mixing TAGS, its like you tell me i have CAR and i tell you no its bike and you keep telling me no its car
No valid HTML (it works but never learn like this !):
<a> <li> sdsad </li> </a>
VALID HTML:
<li><a> sdsad </a></li>
better read all MDN link under all videos :)
Jennifer Nordell
Treehouse TeacherHi there! Patrik Horváth is correct. You're doing fine, but your tags are a bit backwards. The only allowed immediate descendant of an unordered list is a list item. Right now, your list items are inside your links, but your links need to be inside your list items. You can find the rule about the descendants under "Permitted content" in this MDN documentation.
Hope this helps!
Christina Araujo
Full Stack JavaScript Techdegree Student 4,819 PointsThank you Patrick! Most certainly will do.