How to create list in html
8/24/2021
Hacker
HTML List
HTML offers web developers three ways for defining lists of information in html. All html lists must include one or more list elements. Lists may include.
Types of list
There are three different types of list in html:
- Ordered List or Numbered List (ol)
- Unordered List or Bulleted List (ul)
- Description List or Definition List (dl)
Note: you can create the html list inside another list , that will be termed as nested List.
HTML Ordered List or Numbered List
In the ordered lists, all list items are marked with numbers via defaultly. It is known as numbered list also. The ordered list starts with <ol> tag and the list items start with <li> tag.
Example
Output
- first
- second
- third
- fourth
HTML Unordered List or Bulleted List
In HTML Unordered list, all the list items are marked with bullets. It is also known as bulleted list also. The Unordered list starts with <u>> tag and list items start with the <li> tag.
Example
Output
- w3
- code
- designer
HTML Description List or Definition List
HTML Description list is the list style which supported by HTML and XHTML. Description list is also known as definition list where content are listed as a dictionary.
The definition list is very appropriate when user want to show glossary, terms list or another list of name or values.
The HTML definition list contains following three tags:
- <dl> : tag defines the start of the list.
- <dt> : tag defines a term.
- <dd> : tag defines the term definition (description).
Example
Output
- W3CodeDesigner
- -It is India's Largest Coding Site.
- HTML List
- -In this chapter you will learn how to make list in html.
- HTML Table
- -You can learn About html table in our previous Tutorial.
HTML Nested List
A list within another list is termed as nested list. If we want number list inside the bullet list then such type of list called as nested list.
There are an example of html nested list.
Example
Output
-
w3
- W3 is world wide web
- code
-
designer
- Designer designs code.
No comments:
Post a Comment