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 trialKerri Nussbaum
257 PointsCode gives error? <ul> <LI>Shapes</LI> <ol> <li>Circle</LI> </ol> </ul>
Instructed to insert ordered list into "shapes", which is unordered list. My code is producing an error. Why?
<!DOCTYPE html>
<html>
<head>
<title>HTML Lists Challenge</title>
</head>
</html><body>
<h1>HTML Lists Challenge</h1>
<ol>
<LI>Stop</LI>
<LI>Drop</LI>
<LI>Roll</LI>
</ol>
<ul>
<LI>Shapes</LI>
<ol>
<li>Circle</LI>
</ol>
<LI>Colors</LI>
</uL>
</ul>
</body>
3 Answers
Jennifer Cyr
2,302 PointsTry:
<ul>
<li>Shapes
<ol>
<li>Circle</li>
</ol>
</li>
</ul>
Kaleena Perkins
14,792 PointsHi,
You want to make sure you're using lowercase letters when you declare the list items; use "li" rather than "Li".
<ol>
<li>list item 1</li>
<li> list item 2</li>
</ol>
Hope that helps! Take care, Kaleena
John Tasto
21,587 PointsYou should probably wrap your ol
tag with an li
. The ul
is expecting a bunch of li
s inside it, and suddenly it comes across an ol
, which it doesn't know what to do with. Wrapping your ol
in an li
will make sure the outer ul
will have no direct children that are not li
s.
Note - edited because my tags weren't showing up.
Also note - capitalization doesn't matter in HTML, but it is nice to be consistent.
Brian O'Grady
10,094 PointsBrian O'Grady
10,094 PointsYour section
has a small differentiation, you started using <LI> but before circle you used <li> but end it with </LI>.
Try using similar text.