SEARCH OUR SITE
HOME TUTORIALS RESOURCES SEARCH ABOUT US CONTACT US HELP
 Guide to Learning HTML - Tutorial - Lists
List, List and List
There are three kinds of lists in HTML. They are unordered list, oredered list and definition list.

Making unordered lists
Unordered lists are lists that are not numbered. Unordered lists have a bullet before each list item.
Here is an example:
<ul>
<li>Orange
<li>Apple
<li>Pear
</ul>
  • Orange
  • Apple
  • Pear
An unordered list is opened with the <ul> tag. Each item is opened with the <li> tag. The <li> tag does not require the closing tag.
There are three bullet types for unordered lists. They are disc, circle and square. The default one is bullet.
Here is an example:
 <ul>
 <li type=disc>The Disc
 <li type=circle>The Circle
 <li type=square>The Square
 </ul>
  • The Disc
  • The Circle
  • The Square

Making ordered list
Ordered lists are used to present information in numbered format which is ordered.
Here is an example:
<ol>
<li>This is number one
<li>This is number two
<li>This is number three
</ol>
  1. This is number one
  2. This is number two
  3. This is number three
You can modify the look of the bullets by using the type or start attributes in the <OL> tag.
The type attribute supports the following values: A, a, I, i, or 1.
The start attribute specifies at what point to start counting from.
<ol type=I>
<li>Chapter 1
<li>Chapter 2
<li>Chapter 3
</ol>
  1. Chapter 1
  2. Chapter 2
  3. Chapter 3
<ol type=A start=5>
<li>Section E
<li>Section F
<li>Section G
</ol>
  1. Section E
  2. Section F
  3. Section G

Making definition lists
A definition list consists of a definition term and a definition definition.
<dl>
<dd>WWW
<dt>World Wide Web
<dd>HTML
<dt>HyperText Markup Language
<dd>FTP
<dt>File Transfer Protocol
</dl>
WWW
World Wide Web
HTML
HyperText Markup Language
FTP
File Transfer Protocol
Each definition term should be followed by the <dt> tag and each definition definition should be followed by the <dd> tag.
The <dt> and <dd> tags should be put between <dl> and </dl>
The <dt> and <dd> tags do not require a closing tag.


Choose a topic
 Basic HTML
  - Basic
  - Background
  - Links
  - Images
 Intermediate HTML
  - Font Size
  - Text
  - Lists
  - Background Music
 Advanced HTML
  - Tables
  - Frames
  - Meta Tag
 Quick Reference
  - HTML Tags
  - Special Characters
 Location: /28461/lists.htm
PREVIOUS PAGE NEXT PAGE

| Home | Tutorials | Resources | Search | About Us | Contact Us | Help |


This web site is best viewed with 800 x 600 High Color,
Internet Explorer 4.0 or Netscape 4.0 or later versions.
This entire site, except for licensed resources,
Copyright © 1999 by Team28461 All rights reserved.