CSS LIST-STYLE-IMAGE

  • Share
  • Share

This property indicates a graphic to be used for the list markers in the list structure. This should override the default appearance of list-markers in the current HTML list structure. If a ‘list-style-image’ is given a value of ‘none’ or the URL can not be loaded, the ‘list-style-type’ will be used in its place. The ‘list-style-type’ should always be specified in the event the URL pointed to in ‘list-style-image’ can not be loaded
 

Example

ul { list-style-image: url(http://www.example.com/pic.gif) }

<ul><li style=”list-style-image: url(http://www.example.com/pic.gif)”>content</li></ul>

 

Possible Values

Value Description
inherit Explicitly sets the value of this property to that of the parent
none No list-marker will be displayed for the list item
[url] This value indicates the URL source for the list-marker graphic. It can be either an absolute or relative URL. If the graphic can not be loaded, whatever ‘list-style-type’ property is set will be used