Ordered List Example : ol « Tags « HTML / CSS






Ordered List Example

    
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<title>Ordered List Example</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
</head>
<body>

<div class="head">Ordered List Example</div>
<br />
<div class="content">

<p>Ordered lists can be very simple.</p>
<ol>
<li>Item 1</li>
<li>Item 2</li>
<li>Item 3</li>
</ol>
<p>Ordered lists can have a variety of types.</p>
<ol>
<li type="a">Lowercase letters</li>
<li type="A">Uppercase letters</li>
<li type="i">Lowercase Roman numerals</li>
<li type="I">Uppercase Roman numerals</li>
<li type="1">Arabic numerals</li>
</ol>
<p>Ordered lists can start at different values
and with different types.</p>
<ol start="10" type="a">
<li>This should be j</li>
<li value="3">This should be c
<ol>
<li>Lists can nest
<ol>
<li>Nesting depth is unlimited</li>
</ol>
</li>
</ol>
</li>
</ol>

</div>

</body>
</html>

   
    
    
    
  








Related examples in the same category

1.'ol' creates an indented numbered (ordered) list
2.'start' specifies the starting number in an ordered list
3.'type' defines the style for the list items
4.Unordered Lists
5.OL tag
6.Style for 'ol li'
7.list-style: none for OL
8.Add border to LI tag
9.Nested OL tag
10.Three level OL list
11.ol elements without a type attribute: have a numeric sequence type (i.e., 1, 2, ...)
12.A nested ordered list
13.Example of the start Attribute
14.Example of the value Attribute
15.Ordered lists started at 5
16.Numbering options on ordered lists
17.ol { counter-reset:Item }
18.ol {list-style-type: lower-roman;}