Unordered Lists
Unordered lists are a traditional way to create bullet pointed lists about information, that doesn’t need to be in a particular order.
Key Points
Displays a list of items in a bullet pointed list.
To create an ordered list you need to use the <ul> and </ul> tags.
Each item on your list needs to be stored in <li> and </li> tags.
- Item 1
- Item 2
- Item 3
- Item 4
Adding an Unordered List
To add an unordered list to your page you must first create the list by opening your list with an <ul> tag and closing your list with the </ul> tag.
Inside of these tags, you can then create each list item by opening the <li> tag and closing it with the </li> tag.
You can create as many List Items as you need.
<ul>
<li>This is list item 1</li>
<li>This is list item 2</li>
<li>This is list item 3</li>
<li>This is list item 4</li>
</ul>
Styling an Unordered List
When styling an ordered list, it is important to decide if you’re styling the whole list or individual list items.
Add style to the whole list
ul{
color: pink;
background-color: black;
font-size: 30px;
font-family: "Times New Roman";
text-align: center;
}
Add style to the list items
li{
color: pink;
background-color: black;
font-size: 30px;
font-family: "Times New Roman";
text-align: center;
}