Adjusting List Properties with CSS

Cascading Style Sheets introduce a few extra list-formatting possibilities, as Table 52.2 shows.

Table 52.2. CSS List Attributes
ATTRIBUTECONTROLSPOSSIBLE VALUESEXAMPLE
list-style-imageThe image to display in place of a bullet or leading characterurl(imagepath), noneul {

list-style-image: url(../images/bullet.gif);

}
list-style-positionThe position of the bullet or leading character in the list itemsinside, outside relation tool {

list-style-position: inside;

}
list-style-typeThe type of bullet or leading character to displaydisc, circle, square, decimal, lower-roman, uppper-roman, lower-alpha, upper-alpha, noneol {

list-style-type: lower-roman;

}

Replacing Bullets with an Image

Probably the most fun of these attributes ...

Get Web Design Garage now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.