Re: ul tag

BRIANCIZME wrote:

 > This is just a suggestion. I validated a page and was missing <li>
 > tags in a <ul>. The validator  recommended that I had rearranged
 > tags. The code was <div><ul></ul></div>. It recommended that
 > somewhere in my document I had reversed end tags as in </div></ul>.
 > I searched the document for ten minutes for the rearranged end tags.
 > I then used Tidy, it showed me where I missed the tags. After
 > thumping my forehead a couple of times for looking right over it I
 > proceeded to validate the page. I was just shocked that the validator
 > had suggested rearranged tags and not the missing <li> tags. Maybe
 > that will help some one else out in the future?

Are you not being a little disingenuous, Brian ?  Although the
Validator's /first/ message suggests improper nesting, the second
message addresses your very case :

 > Most likely, you nested tags and closed them in the wrong order. For
 > example <p><em>...</p> is not acceptable, as <em> must be closed
 > before <p>. Acceptable nesting is: <p><em>...</em></p>
 >
 > Another possibility is that you used an element which requires a
 > child element that you did not include. Hence the parent element is
 > "not finished", not complete. For instance, in HTML the <head>
 > element must contain a <title> child element, lists require
 > appropriate list items (<ul> and <ol> require <li>; <dl> requires
 > <dt> and <dd>), and so on.

Philip Taylor

Received on Monday, 6 August 2012 09:49:41 UTC