Lists of things are pretty useful in ordinary text, but in HTML, where you'll often have lists of links to other places, they're even more useful. However WWW servers just consisting of lists are pretty boring too, and with some imagination, you'll find more interesting ways to present many things.
The simplest list is the bullet or unordered list, which is denoted by <UL>, and the list items in it are denoted using <LI>. An example is:
Oxymorons: <UL> <LI>Military Intelligence <LI>Plastic Glasses <LI>Moral Majority </UL>This would be displayed as:
Oxymorons:Another form of list is the numbered or ordered list denoted by <OL>. Ordered lists have the same syntax as unordered lists except that OL replaces UL in the list delimiters:
- Military Intelligence
- Plastic glasses
- Moral majority
Oxymorons: <OL> <LI>Business ethics <LI>Chilli </OL>This gets displayed as:
Oxymorons:
- Business ethics
- Chilli
A more complex type of list is the definition list, denoted by <DL>. definition terms are denoted using <DT> and actual definition data is denoted using <DD>, so a typical list may be:
Population Statistics: <DL> <DT>Ireland <DD>population 3 million <DT>Scotland <DD>population 5 million <DT>England <PP>population too many </DL>which would be presented as:
Popu¯ lati¯ on Statistics:Ireland
population 3 million
Scotland
population 5 million
England
population too many
If you wish to have several paragraphs of definition data associated with one definition term, simply use several <DD> entries.
Note that although the <DL> list must be finished with a </DL>, each <DT> or <DD> list item is simply ended by the next definition.