This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 3170 - optional </li> close tag causes validation error with nested ol's
Summary: optional </li> close tag causes validation error with nested ol's
Status: RESOLVED INVALID
Alias: None
Product: Validator
Classification: Unclassified
Component: check (show other bugs)
Version: HEAD
Hardware: PC Windows XP
: P2 normal
Target Milestone: ---
Assignee: Terje Bless
QA Contact: qa-dev tracking
URL: http://alamo.nmsu.edu/~spodhaje/sitem...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-05-01 16:47 UTC by Steve Podhajecki
Modified: 2006-05-01 16:50 UTC (History)
0 users

See Also:


Attachments

Description Steve Podhajecki 2006-05-01 16:47:07 UTC
The following fails validation:
					<div>
					<ol class="lvl1">
					<li><a href="index.php">Home</a> This is main page of this site.</li>
						<ol class="lvl2">
							<li><a href="sitemap.php">Site Map</a> <em> You are here.</em></li>
							<li><a href="contact.php">Contact</a> This link will take you to a form where you can leave a message.</li>
							<li><a href="picture.php">Picture</a> This is a picture from 2005. When we had some snow.</li>
							<li><a href="flash.php">Flash</a> This link will take you to a Flash presentation on use a rescue disk.</li>
							<li><a href="assign7.php">Assign7</a> This page is the rest of Assignment 7, php and audio.
							<li><a href="Assign_8.php">Assign 8</a> PHP calculator script.
							<li><a href="Extra_credit.php">Extra Credit</a> Extra credit assignment.
							<li><a href="links.php">Links</a> This will take you to a page with some interesting links for programmers.</li>
						</ol>
						
					</ol>
					</div>


However, removing the optional list item closing tag from the top level list allows the page to validate. 
http://alamo.nmsu.edu/~spodhaje/sitemap.php
Comment 1 Bj 2006-05-01 16:50:10 UTC
Your code is <ol><li></li><ol>... which is not allowed, the inner <ol> must be part of a list item.