Quick References
      ADO
      ASP
      CSS2
      HTML
      JavaScript
      Jet SQL
      VBScript
      WML
      WMLScript
      WSH
      XHTML
      XML DOM
      XSLT

Features
      Knowledge Base
      Tutorials

Partners
     ZVON.ORG
     XML
     Planet Source Code
     VisualBuilder
     Web Design
     Your HTML Source
     XML/XSLT Forums
     ASPAlliance
     Scripts
     
     Programmers Heaven
     Tek-Tips Forums
     Developer Fusion
     Code Project









TAG:  ol

<ol> ... </ol>
 
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 separate closing tag is mandatory.
 
Attributes and Events
 
class    dir    id    lang    onclick    ondblclick    onkeydown    onkeypress    onkeyup    onmousedown    onmousemove    onmouseout    onmouseover    onmouseup    style    title
 
Code:
<?xml version="1.0" encoding="UTF-8"?>
<!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" xml:lang="en" lang="en">
<head>
<title>DevGuru XHTML ol Tag Example</title>
</head>
<body>
Three Major Types Of Lists:
<ol>
<li> Definition List</li>
<ol>
<li> dd tag</li>
<li> dl tag</li>
<li> dt tag</li>
</ol>
<li> Ordered List</li>
<ol style="list-style-type: upper-roman;">
<li> ol tag</li>
<li> li tag</li>
</ol>
<li> Unordered List</li>
<ol style="list-style-type: lower-alpha;">
<li> ul tag</li>
<li> li tag</li>
</ol>
</ol>
</body>
</html>

 
Output:
Three Major Types Of Lists:
  1. Definition List
    1. dd tag
    2. dl tag
    3. dt tag
  2. Ordered List
    1. ol tag
    2. li tag
  3. Unordered List
    1. ul tag
    2. li tag


 


Copyright 1999-2005 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information