Search Helium

Home > Computers & Technology > Internet > Web Design

How to design lists in HTML code

by N. Rodriguez

Created on: August 11, 2009

Normally, when creating a webpage, you have a purpose in mind. You have a goal, you have something you want to get across to the reader, you have something you want to sell them, you have information they should know, or you just want to tell them about your life. No matter what the goal of your website is, at one point or another you are going to need to have a list. Lists are an excellent way to present information neatly, and keep it organized and easy to read.

When using HTML there are three different types of list available to you, the ordered list, the unordered list, and the definition list.

Lets begin with the first type of list i mentioned, the ordered list. The ordered list is most commonly used when you are listing places, as in finishing in first, second, and third place. This is because in an ordered list each list item will have a number in from of it, starting with one, and continuing on to however many list items you have. Here is an example of an ordered list.

<OL> (This tag beings the ordered list)

<LI>(This tag specifies that the following is a list item) Milk </LI>

<LI>Eggs</LI>

<LI>Butter</LI>

</OL>(This tag ends the ordered list)

On a webpage, that list would like this

1. Milk

2.Eggs

3. Butter

Now, lets move on to the second list mentioned, the unordered list. The unordered list is written with the same basic code structure as the ordered list, the only difference is the opening and closing tags. The only difference between the two lists is that an Unordered list uses bullets instead of numbers. Here is an example.

<UL> (This tag beings the unordered list)

<LI>(This tag specifies that the following is a list item) Milk </LI>

<LI>Eggs</LI>

<LI>Butter</LI>

</UL>(This tag ends the unordered list)

On a webpage, that list would like this

* Milk

* Eggs

* Butter

The final HTML list that I will be explaining is the Definition List. The definition list is not commonly used for some reason, but it is a very usable and useful list. In a definition list there are two parts to each list item, normally it is the name of an item, and then a brief description, or definition, of it. Here is an example.

<DL>(This tag begins the definition list)

<DT>(This is the main word on the list) Derek Jeter </DT>

<DD>(This is the definition)Yankee's Shortstop </DD>

<DT> Alex Rodriguez </DT>

<DD> Yankee's Third Baseman </DD>

</DL>

This list would appear on a webpage like this-

Derek Jeter

Yankee's Shortstop

Alex Rodriguez

Yankee's Third Baseman

Well, there you have it, a brief explanation of the different types of HTML lists, I hope this article will help you to better organize information on your webpage, happy coding!

Learn more about this author, N. Rodriguez.
Click here to send this author comments or questions.

Helium Debate

Cast your vote!

Are website designers highly paid?

Click for your side.

91517

Featured Partner

Chesapeake Service Systems

Chesapeake Service Systems (CSS) has partnered with Helium, giving you the chance to write for a cause. Browse CSS' featured titles, pick an issue and write! You can also donate your article earnings. Share what you know, ...more


CONNECT WITH US

Read
our blog
Helum for writers

Write and get published
Share with other writers
Polish your freelancing skills

Join our active writing community
Helium Content Source for Publishers

Quality articles from proven freelancers
Exclusive rights, fast turnaround
Brand engagement, business blogging -- our writers do it all

Get custom content today!

INFORMATION


Helium, Inc.
200 Brickstone Square Andover, MA 01810 USA
#