Lists




<<<Previous Tutorial>>>

Next Tutorial>>>

HTML provides a way to create both an ordered list (with elements counting up, 1, 2, 3…) and an unordered list with bullets instead of numbers. Lists are a good way to formalize a list of items and let the HTML styling do the work for you.

Ordered lists

Here is an example of how to create an ordered list:

Ordered lists have a “type” attribute which defines the numbering convention to use.

To count using numbers, use type=”1″:

To count using uppercase letters, use type=”A”:

To count using lowercase letters, use type=”a”:

To count using uppercase roman numerals, use type=”I”:

To count using lowercase roman numerals, use type=”i”:

Unordered lists

Here is an example of how to create an unordered list:

To change the list style attributes, we can use the CSS attribute called list-style-type. The available types are:

  • disc
  • circle
  • square
  • none

Here is an example of the disc list style type:

Here is an example of the circle list style type:

Here is an example of the square list style type:

Here is an example of the none list style type:

 

<<<Previous Tutorial>>>

Next Tutorial>>>