8 Lists

There are three basic types of list in HTML:

Ordered Lists
These lists are created using the <ol>...</ol> tags. Inside this ordered list environment each listed item is specified with <li>...</li> tags. Each item in an ordered list is numbered, e.g. try:
<ol>
<li> Find plans. </li>
<li> Save world. </li>
<li> Get out of my house! </li>
</ol>
Unordered Lists
These lists are created using the <ul>...</ul> tags, but other than that the syntax is the same as for an ordered list. Inside this unordered list environment each listed item is specified with <li>...</li> tags. The list items in an unordered list are not numbered, and are usually indicated with bullet points.
Definition Lists
These lists are created using the <dl>...</dl> tags. Inside this definition list environment the terms you want defined are enclosed in <dt>...</dt> tags, and the definition description is enclosed in <dd>...</dd>. Definition lists are used when you want a list of terms along with their definitions, such as this very list! E.g.:
<dl>
<dt> HTML
<dd> HTML stands for Hypertext Mark-Up Language, and is the language of the World-Wide Web. </dd>
</dt>
<dt> Frames
<dd> Frames are nasty, evil things some people put in their web pages. 
They are abhorrent and should be avoided at all costs.</dd>
</dt>
</dl>

Exercise 8

Use an unordered list to list your research interests. You might even like to nest lists inside each other.

Now your web page might look like this.


Previous page Next page