From the course: HTML Essential Training
Unlock this course with a free trial
Join today to access over 24,900 courses taught by industry experts.
Ordered, unordered, and description lists
From the course: HTML Essential Training
Ordered, unordered, and description lists
- Something we use in our everyday lives are lists, like shopping lists or to-do lists. So, it's not surprising that we'll also need to use lists in HTML to organize our content. There are three types, ordered, unordered, and description. Ordered lists are for items that follow a specific sequence, like directions or recipe steps. Unordered lists are for items that do not need to follow a specific order. And description lists are used to organize related terms and their descriptions. Let's take a look at the syntax. All list items are written as li tags, for ordered lists, the items are grouped using ol tags, and for unordered lists, use the ul tag. Only li tags can be nested inside both types of lists. If you want to include introductory texts, use a paragraph element outside of the ol or ul tag. Let's take a look at a CodePen example. In the first block of text, the content contains directions which need to be in a specific sequence, so an ordered list is used. When using the ol…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
(Locked)
Paragraphs and headings5m 41s
-
(Locked)
Ordered, unordered, and description lists5m 50s
-
(Locked)
Quotations3m 59s
-
(Locked)
Exercise: Formatting text, part 13m 4s
-
(Locked)
Date and time1m 48s
-
(Locked)
Bold and italics2m 25s
-
(Locked)
Character entity reference4m 39s
-
(Locked)
Exercise: Formatting text, part 21m 43s
-
(Locked)
Code and line breaks1m 21s
-
(Locked)
HTML and typography1m 29s
-
(Locked)
Challenge: Write text-based HTML markup for course project2m 52s
-
(Locked)
Solution: Demo3m 46s
-
(Locked)
-
-
-
-
-
-
-