Lists: Try-It-Yourself Examples
Lists: Try-It-Yourself Examples
HTML Lists
HTML Lists
Previous
The most common HTML lists are ordered and unordered lists: HTML Lists An ordered list:
1. The first list item 2. The second list item 3. The third list item
Next Chapter
An unordered list:
List item List item List item
Try-It-Yourself Examples
Unordered list How to create an unordered list in an HTML document. Ordered list How to create an ordered list in an HTML document. (You can find more examples at the bottom of this page).
< u l > < l i > C o f f e e < / l i > < l i > M i l k < / l i > < / u l >
How the HTML code above looks in a browser: Coffee Milk
< o l > < l i > C o f f e e < / l i > < l i > M i l k < / l i > < / o l >
How the HTML code above looks in a browser: 1. Coffee
w3schools.com/html/html_lists.asp 1/3
4/4/13
HTML Lists
2. Milk
< d l > < d t > C o f f e e < / d t > < d d > -b l a c kh o td r i n k < / d d > < d t > M i l k < / d t > < d d > -w h i t ec o l dd r i n k < / d d > < / d l >
How the HTML code above looks in a browser: Coffee - black hot drink Milk - white cold drink
More Examples
Different types of ordered lists Demonstrates different types of ordered lists. Different types of unordered lists Demonstrates different types of unordered lists. Nested list Demonstrates how you can nest lists. Nested list 2 Demonstrates a more complicated nested list. Definition list Demonstrates a definition list.
w3schools.com/html/html_lists.asp
4/4/13
HTML Lists
<dt> <dd>
Previous
Next Chapter
w3schools.com/html/html_lists.asp
3/3