HTML - Lists
HTML has three types of lists. <ol> shows a ordinate list while <ul> a disorderly
one, and for making a definition list is used <dl>. Use the attributes type and start
for making a list in order with your requests.
- <ul> - unsorted list, bullets
- <ol> - ordered list, umbers
- <dl> - definition list.
HTML - The ordered list
Use <ol> tag for starting a ordered list. if you put <li></li> (list item) between
<h4 align="center">Objectives</h4> <ol> <li>To find a job </li> <li>To take a lots of money </li> <li>To move in an other city</li> </ol> |
Display
Objectives
|
You can start your list with any number you want just specifying it with the
help of the start attribute.
<h4 align="center">Objective</h4> <ol start="4" > <li>To find a job </li> <li>To take a lots of money </li> <li>To move in an other city</li> </ol> |
Display
Objectives
|
This element is not doing anything out of common but is pretty useful sometimes.
HTML - Other types of ordered lists
Excluding the upper example there are other for types of ordered lists.In the place of the arabian numbers you can use roman numbers or as well letters but in both cases it can be used only small letters or capital letters. Use the type attribute if you want to modify the type of the numbering
<ol type="a"> <ol type="A"> <ol type="i"> <ol type="I"> |
Display
| Small letters | Capital letters | Roman numbers with small letters | Roman numbers with capital letters |
|
|
|
|
Unsorted list
It makes a unsorted list with the help of the <ul> tag. The disordered lists are splinted in many types : squares, bullets, and circles. The standard value gave by the majority of the browsers are bullets.
<h4 align="center">Shopping list </h4> <ul> <li>milk</li> <li>cheese</li> <li>eggs</li> <li>sugar</li> </ul> |
I have put together in the next example how it looks the other types of unsorted lists.
<ul type="square"> <ul type="disc"> <ul type="circle"> |
HTML - The definition list
As well you can make definition lists using the <dl> tag. This list will give the word above de definition. It is indicated to bold the word so that it will be more evident.
<dl> <dt><b>Quieso</b> </dt> <dd>Spanish word for cheese .</dd> <dt><b>Ordenador</b></dt> <dd>Spanish word for Computer </dd> </dt> |
