asp.net.ph

Skip Navigation LinksHome > Abakada: Back to Basics > Language References > HTML Elements > OL Element

<OL Element | OL Object


Displays lines of text as a numbered or ordered list.

HTML Syntax

Remarks

The OL element displays an ordered, or numbered, list. The element is used with the LI element to designate the individual list items.

The default numbering style is determined by the browser, but authors can use the element’s type attribute to change the list's numbering sequence and style.

This element is a block element.

NOTE: Both start and end tags are required.

Attributes

The <ol> element supports the following attributes, in addition to global attributes common to all HTML elements.

AttributeValueDescription
reversedreversedSpecifies that the list order should be reversed (9,8,7...)
startnumberSpecifies the start value of an ordered list
type1, A, a, I, iSpecifies the kind of marker to use in the list

Example

<p>To create an ordered list. </p>
<ol>
   <li>Mark the start of the list with the OL tag
 <li>Mark the beginning of each list item with 
  the LI tag
 <li>Mark the end of the ordered list.
</ol>

To create an ordered list.

  1. Mark the start of the list with the OL tag
  2. Mark the beginning of each list item with the LI tag
  3. Mark the end of the ordered list.

See Also

DIR, LI, MENU, UL, Using Lists in HTML



Check out related books at Amazon

© 2025 Reynald Nuñez and asp.net.ph. All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note