<ol type=""><li type="">

Browser
  • IE
  • Cr
  • Sf
  • Fx
  • O
Type

The type attribute of the OL element changes the numbering type.

The type attribute in the OL tag : Applied to all items in the list.


<ol type="A">
<li>first list item</li>
<li>second list item</li>
<li>third list item</li>
</ol>

The type attribute in the LI tag : Applied to one item.


<ol>
<li type="1">first list item</li>
<li type="A">second list item</li>
<li type="a">third list item</li>
<li type="I">fourth list item</li>
<li type="i">fifth list item</li>
</ol>

Attribute Value Explanation
type=" " 1 arabic numeral
A alphabet (capital letter)
a alphabet (small letter)
I roman numeral (capital letter)
i roman numeral (small letter)

The use of this attribute is deprecated. (Use CSS instead)

Example


<ol type="A">
<li>First list item</li>
<li>Second list item</li>
<li>Third list item</li>
</ol>

Output
  1. First list item
  2. Second list item
  3. Third list item

<ol>
<li type="1">Arabic numeral</li>
<li type="A">Alphabet (capital letter)</li>
<li type="a">Alphabet (small letter)</li>
<li type="I">Roman numeral (capital letter)</li>
<li type="i">Roman numeral (small letter)</li>
</ol>

Output
  1. Arabic numeral
  2. Alphabet (capital letter)
  3. Alphabet (small letter)
  4. Roman numeral (capital letter)
  5. Roman numeral (small letter)