Lists tag


You can have a sequence of lines or items, and you can list them. Your list may be ordered or unordered. There are 2 tags: <OL> and <UL>. <OL> means Ordered List and <UL> means Unordered List.

Unordered list

Let's see the <UL> tag:

<UL TYPE=item> where item may be:

  1. Nothing (I mean that if you don't use the TYPE parameter at all, a solid circle will be shown)
  2. CIRCLE (a void circle will be shown)
  3. SQUARE (a square will be shown)

Each list's item, is defined by means of the <LI> tag (List Item):

<LI VALUE="number" TYPE=item>

Warning: you can use the VALUE parameter within an ordered list (<OL>) only. I mean that you CAN'T use the VALUE parameter within an unordered list (<UL>)!

The TYPE parameter is shown above. By means of the VALUE parameter, you can change the value of the single item within an ordered list, but now we are talking about unordered lists...Too much complicated? Don't worry, here a few of examples:

* Sample 1 *

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<UL>
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI>Item 4</LI>
</UL>
</body>
</html>

* Sample 2 *

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<UL TYPE=SQUARE>
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI>Item 4</LI>
</UL>
</body>
</html>

Ordered lists

Now, let's see the <OL> tag:

<OL START="number" TYPE=item> where item may be:

  1. Nothing (I mean that if you don't use the TYPE parameter at all, a number will be shown)
  2. I (an upper case roman number will be shown)
  3. i (a lower case roman number will be shown)
  4. A (an upper case letter will be shown)
  5. a (a lower case letter will be shown)

The START parameter will be discuss later. Each list's item, is defined by means of the <LI> tag (List Item) like on unordered list, but here you can use the VALUE parameter:

<LI VALUE="number" TYPE=item>

Warning: you can use the VALUE parameter within an ordered list (<OL>) only!

The TYPE parameter is shown above. By means of the VALUE parameter, you can change the value of the single item within an ordered list...Too much complicated? Don't worry, here a few of examples:

* Sample 1 *

  1. Item 1
  2. Item 2
  3. Item 3
  4. Item 4

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<OL>
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI>Item 4</LI>
</OL>
</body>
</html>

Pay attention at the <OL> tag. Remember: now we are talking about ordered lists...

* Sample 2 *

  1. Item 1
  2. Item 2
  3. Item 3
  4. Item 4

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<OL TYPE=i>
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI>Item 4</LI>
</OL>
</body>
</html>

Pay attention at the TYPE parameter...

* Sample 3 *

  1. Item 1
  2. Item 2
  3. Item 3
  4. Item 4

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<OL TYPE=A>
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI>Item 4</LI>
</OL>
</body>
</html>

Pay attention at the TYPE parameter...

VALUE parameter

By means of the VALUE parameter, you can change the number of a specific item within an ordered list. Remember the START parameter inside of the <OL> tag? Well, the START parameter indicates the first number of that list. In other words, if you put, say 6, inside of the START parameter, that list will start from 6. Examples:

  1. Item 1
  2. Item 2
  3. Item 3
  4. Item 4
  5. Item 5
  6. Item 6

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<OL START="6">
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI>Item 4</LI>
<LI>Item 5</LI>
<LI>Item 6</LI>
</OL>
</body>
</html>

You want to build a list starting from 6 and you want to change the fourth item? Look:

  1. Item 1
  2. Item 2
  3. Item 3
  4. Item 4
  5. Item 5
  6. Item 6

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<OL START="6">
<LI>Item 1</LI>
<LI>Item 2</LI>
<LI>Item 3</LI>
<LI VALUE="99">Item 4</LI>
<LI>Item 5</LI>
<LI>Item 6</LI>
</OL>
</body>
</html>

You can also build sub-lists, by using the right combination of <OL> and </OL> tags. Look:

  1. Item 1
    1. Item 2
    2. Item 3
  2. Item 4

And this is the HTML page's source:

<html>
<head>
</head>
<body>
<OL>
<LI>Item 1</LI>
<OL>
<LI>Item 2</LI>
<LI>Item 3</LI>
</OL>
<LI>Item 4</LI>
</OL>
</body>
</html>

In other words: red tags meaning starting/ending of the list. The yellow tag means that you want to put another ordered list inside of the first one. The green tag means that you want to end the second list, so the next item will belong to the originary list.


Index           Home  Back  Forward       About  Contact us!

Copyright (c) 1998-2006 Wowarea