ListsHTML supports unnumbered, numbered, and definition lists. You can nest lists too, but use this feature sparingly because too many nested items can get difficult to follow. Unnumbered ListsTo make an unnumbered, bulleted list:
Below is a sample three-item list: <ul> <li> apples <li> bananas <li> grapefruit </ul> The output is:
The <li> items can contain multiple paragraphs. Indicate the paragraphs with the <p> paragraph tags.
Numbered ListsA numbered list (also called an ordered list, from which the tag name derives) is identical to an unnumbered list, except it uses <ol> instead of <ul>. The items are tagged using the same <li> tag. The following HTML code: <ol> <li> oranges <li> peaches <li> grapes </ol> Produces this formatted output:
Nested ListsHere is a sample nested list: <ul> <li> A few New England states: <ul> <li> Vermont <li> New Hampshire <li> Maine </ul> <li> Two Midwestern states: <ul> <li> Michigan <li> Indiana </ul> </ul> The nested list is displayed as:
|