DEV Community

Cover image for Day-2 of Learning HTML
Raksha
Raksha

Posted on

Day-2 of Learning HTML

Hi Guys, this is my day-2 of learning HTML. Today I learned about the different types of list in HTML.

Types of List:

        -  Ordered List
- Unordered List
- Description List
Enter fullscreen mode Exit fullscreen mode




Ordered List:

  1. 1. Ordered list is used when we want the items to be listed in the sequential order.
  2. <ol> tag refers to the Ordered List
  3. 2. Here, we can order the items in Numbers, Alphabets and Roman Numerals using type attribute.
  4. 3. We can also reverse the order of the List using reversed attribute.
  5. 4. We can also specify the starting of the List using start attribute.

Example:

Unordered List:

  1. 1. Unordered list is used when we don't want the items to be displayed in specific order.
  2. <ul> tag refers to the Unordered List.
  3. 2. By default , the items are displayed in disc.
  4. 3. We can change the style using type attribute.
  5. 4. The other available styles are square, and circle.

Example:

Description List:

Description List is used to display the descriptive term along with the definitions.
<dl> tag refers to the Description List.
<dt> tag refers to the Description term.
<dd> tag refers to the Description Definitions.

Example:

Bye Guys...

Top comments (0)