Chapter 13. Lists

The (X)HTML specifications contain special codes for creating lists of items. You can create plain, numbered, or bulleted lists, as well as lists of definitions. You can also nest one kind of list inside another. In the sometimes sketchy shorthand of the Internet, lists come in very handy.

All lists are formed by a principal code to specify what sort of list you want to create (ol for ordered list, dl for definition list, etc.) and a secondary code to specify what sort of items you want to create (li for list item, dt for definition term, etc.).

Although the W3C does not recommend the use of list elements for simply indenting paragraphs, they are rather handy in this regard. You can find more information about that in Chapter 22 ...

Get HTML for the World Wide Web, Fifth Edition, with XHTML and CSS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.