webmaster resources tips and articles
webmaster information

Path = Home : HTML Design Tips : How To Change The Style Of Bullets In Lists

How To Change The Style Of Bullets In Lists

 

The <ul> tag is used to create unordered lists, that is, lists which are not numbered and can be in any order that you wish.

You can change the style of the bullets in lists by adding attributes to the <ul> or <li> tags. There are three styles of bullet available, disc, circle and square.

To use the same bullet type for each item you add it to the <ul> tag.

The disc bullet

Note that the disc is the default value so if you don't specify a bullet style the disc will be the one that is used.

<ul>
<LI>Item 1
<LI>Item 2
<LI>Item 3
</ul>

  • Item 1
  • Item 2
  • Item 3

The circle bullet

<ul>
<LI type="circle">Item 1
<LI type="circle">Item 2
<LI type="circle">Item 3
</ul>
  • Item 1
  • Item 2
  • Item 3

The square bullet

<ul>
<LI type="square">Item 1
<LI type="square">Item 2
<LI type="square">Item 3
</ul>
  • Item 1
  • Item 2
  • Item 3

Mixed bullets

If you want to mix the bullet types you can add them to the <li> tags

<ul>
<LI type="disc">Item 1
<LI type="circle">Item 2
<LI type="square">Item 3
</ul>

  • Item 1
  • Item 2
  • Item 3

 

 

© janim.net 2000 - 2007 All rights reserved