Learn HTML step-by-step from A to Z or improve your professional skills.  Home HTML and CSS Tutorials Making Lists
Your Ad Here

Making Lists


The <UL> Tag

<UL>
<LI> This is item number 1.
<LI> This is item number 2.
</UL>
Making Lists

The UL and LI tags are used to create unordered lists. Unordered simply means there is no numbering scheme involved. You must close all <UL> tags with a </UL>.

You can also use UL with the COMPACT attribute, <UL COMPACT> which will tell the browser to squeeze the list when possible. This is good for side bar menu links.

The <OL> & Tag

<OL>
<LI> This is item number 1.
<LI> This is item number 2.
</OL>

The OL and LI tags are used to create ordered lists. Ordered simply means there is a numbering scheme involved. You must close all <OL> tags with a </OL>.

The OL tag allows the following options:

  • TYPE=I use capital Roman numerals
  • TYPE=A use capital letters
  • TYPE=a use lowercase letters
  • TYPE=i use lowercase Roman numerals
  • TYPE=1 use numeric character
You can also do this:
  • TYPE=I START=1 start with capital Roman numeral I
  • TYPE=A START=2 start with capital letter B
  • TYPE=a START=4 start with lowercase letter d
  • TYPE=i START=6 start with lowercase roman number vi
  • TYPE=1 START=3 start with the number 3

The <DL> Tag

<DL>
<DT> Title for Group 1
<DD> First in Group 1
<DD> Second in Group 1
<DT> Title for Group 2
<DD> First in Group 2
</DL>

The DL tag, used in conjunction with the DD and DT tags create lists that contain no numbering or dotting scheme. This is useful for when you want to use your own graphics as bullets, such as:

<DD><IMG SRC="bullet.gif"> First in Group 1

It is best to keep your text as short as possible as wrapped text is not indented.

You can also use DL with the COMPACT attribute, <DL COMPACT> which will tell the browser to squeeze the list when possible. This is good for side bar menu links.


Author's URL: Jeff Singer
Thank you for voting.
Rate this Materials:
Bad 
1 2 3 4 5 Excellent
print this page subscribe to newsletter subscribe to rss

HTML is Hyper Text Markup Language that is used to make hypermedia and hypertext documents for the Web. More HTML and CSS: Most Popular Materials | Fresh Materials | More HTML Tutorials at Markuptutorials.com

Add comments to "Making Lists"

Only registered users can write comment

No comments yet...