Our Top Courses
In HTML, lists are used to present a collection of items in a structured format. There are three main HTML text list Tags :
- Ordered List or Numbered List
- Unordered List or Bulleted List
- Description List or Definition List
Ordered List
- Purpose: To display a list of items in a specific order, usually numbered.
- Tags: <ol>
- Example:
<ol>
<li>First item</li>
<li>Second item</li>
<li>Third item</li>
</ol>
Result
Un-Ordered List
- Purpose: To display a list of items without any specific order or numbering.
- Tags: <ul>
- Example:
<ul>
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ul>
Result
Description List
Purpose: To emphasize text by making it appear bolder.
Tag: <b> or <strong> (<strong> is semantically preferred)
Example:
<dl>
<dt>HTML</dt>
<dd>HyperText Markup Language</dd>
<dt>CSS</dt>
<dd>Cascading Style Sheets</dd>
</dl>
Result