List Handling in HTML
- What are Lists?
-
-
Lists are used to group related pieces of information together, so they are clearly associated with each other and easy to read.
-
In modern web development lists are very important elements, frequently used for navigation as well as general content.
-
Types Of Lists In HTML
There are three list types in HTML:
-
unordered list—used to group a set of related items, in no particular order.
-
ordered list—used to group a set of related items, in a specific order.
-
definition list—used to display name/value pairs such as terms and their definitions, or times and events.
UnOrdered Lists In HTML
Unordered lists, or bulleted lists, are used when a set of items can be placed in any order. An example is a shopping list:
These items are all part of one list, however, we could put the items in any order and the list would still make sense:
- Syntax For Unordered List
-
•We use the <ul> tag to create an unordered list .•Items will appear with bullets•The list items are created with the <li> tag.
<html>
<head>
<title>List Demo 1</title>
<body>
<h3>Courses</h3>
<ul>
<li>C</li>
<li>C++</li>
<li>Java</li>
<li>.Net</li>
<li>Php-MySQL</li>
<li>Oracle</li>
</ul>
</body>
</html>