An HTML List is used to display a group of related items in a structured format.
| Type | Tag | Description |
|---|---|---|
| Ordered | <ol> |
Numbered list |
| Unordered | <ul> |
Bullet list |
| Description | <dl> |
Definition list |
Displays items in a numbered sequence.
<ol> as container<li><li> must be inside <ol>EXAMPLE: Steps to Make Tea
Use the type attribute to change numbering styles:
| Type | Example |
|---|---|
| 1 | 1, 2, 3 |
| A / a | A, B, C / a, b, c |
| I / i | I, II, III / i, ii, iii |
CODE: <ol type="A">
Displays items with bullet points.
| Type | Style |
|---|---|
| disc | ● (Default) |
| circle | ○ |
| square | ■ |
EXAMPLE: Fruits (<ul type="square">)