HTML ol type property
Examples
An ordered list with uppercase Roman numerals:
<ol type="I">
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ol>
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ol>
try it"
Browser Support
All major browsers support the type attribute.
Definition and Usage
type attribute specifies the type of mark (letters or numbers) list that you want to use.
Differences between HTML 4.01 and HTML5
In HTML5, no longer use <ol> element type attribute opposition.
grammar
<ol type="1|a|A|i|I">
Property Value
值 | 描述 |
---|---|
1 | 默认。十进制数字 (1, 2, 3, 4)。 |
a | 字母顺序的有序列表,小写 (a, b, c, d)。 |
A | 字母顺序的有序列表,大写 (A, B, C, D)。 |
i | 罗马数字,小写 (i, ii, iii, iv)。 |
I | 罗马数字,大写 (I, II, III, IV)。 |
HTML <ol> tag