Vlastnost CSS list-style-image
Příklad
Zadejte obrázek jako značku položky seznamu v seznamu:
ul
{
list-style-image: url('sqpurple.gif');
}
Definice a použití
Vlastnost list-style-image
nahradí značku položky seznamu obrázkem.
Poznámka: Vždy navíc zadejte vlastnost list-style-type . Tato vlastnost se používá, pokud je obrázek z nějakého důvodu nedostupný.
Výchozí hodnota: | žádný |
---|---|
Zděděno: | Ano |
Animovatelné: | Ne. Přečtěte si o tématu Animable |
Verze: | CSS1 |
Syntaxe JavaScriptu: | objekt .style.listStyleImage="url('smiley.gif')" |
Podpora prohlížeče
Čísla v tabulce určují první verzi prohlížeče, která plně podporuje vlastnost.
Property | |||||
---|---|---|---|---|---|
list-style-image | 1.0 | 4.0 | 1.0 | 1.0 | 7.0 |
Syntaxe CSS
list-style-image: none|url|initial|inherit;
Hodnoty vlastností
Value | Description | Play it |
---|---|---|
none | No image will be displayed. Instead, the list-style-type property will define what type of list marker will be rendered. This is default | |
url | The path to the image to be used as a list-item marker | |
initial | Sets this property to its default value. Read about initial | |
inherit | Inherits this property from its parent element. Read about inherit |
Související stránky
CSS tutoriál: CSS List
CSS reference: vlastnost ve stylu seznamu
HTML DOM reference: vlastnost listStyleImage