<ol> ... </ol>
Available in versions: 2.0, 3.2, 4.0
The <ol> tag is used to delimit the start and stop of an ordered list.
An ordered list is a collection of items (typically related somehow) that need to be
listed in particular order.
For example, an ordered list could be an index, table of contents, or a set of instructions.
The default is to list each item in numeric order (starting with the number 1).
However, you can also specify Roman numerals or alphabetic characters.
Most browsers separate the list from any preceding and following text by paragraph breaks.
You can nest ordered lists and the nested lists will also be in ordered value.
You must use the li tag to display an item in the list.
You can use the ul tag to create an unordered list and the dl tag to create a
definition list.
(The dir and menu list tags are deprecated.)
The closing tag is mandatory.
Core Attributes
class
dir
id
lang
onclick
ondblclick
onkeydown
onkeypress
onkeyup
onmousedown
onmousemove
onmouseout
onmouseover
onmouseup
style
title
Attributes
compact deprecated 4.0
The compact attribute is used to make an ordered list more compact
in appearance.
This attribute is poorly implemented.
It is deprecated effective with version 4.0.
start deprecated 4.0
The start attribute is used to set the ordering value that the list
will start with (the default is 1).
You can also start with any letter in the alphabet or any Roman numeral.
It is deprecated effective with version 4.0.
type deprecated 4.0
The type attribute determines the characters used to order the list.
The permitted values are: 1 for Arabic numbers;
I or i for upper or lower case Roman numerals;
and A or a for upper or lower case alphabetic characters.
It is deprecated effective with version 4.0.
Code:
Three Major Types Of Lists:
<ol>
<li> Definition List
<ol type="A" start="5">
<li> dd tag
<li> dl tag
<li> dt tag
</ol>
<li> Ordered List
<ol type="i">
<li> ol tag
<li> li tag
</ol>
<li> Unordered List
<ol type="1">
<li> ul tag
<li> li tag
</ol>
</ol>
Output:
Three Major Types Of Lists:
- Definition List
- dd tag
- dl tag
- dt tag
- Ordered List
- ol tag
- li tag
- Unordered List
- ul tag
- li tag
Copyright 2000 by Infinite Software
Solutions, Inc.
Trademark Information
|