Style listStyleImage Proprietà
Esempio
Specificare un'immagine come indicatore della voce di elenco in un elenco:
document.getElementById("myList").style.listStyleImage = "url('sqorange.gif')";
Definizione e utilizzo
La proprietà listStyleImage imposta o restituisce un'immagine come indicatore dell'elemento dell'elenco.
Supporto browser
Property | |||||
---|---|---|---|---|---|
listStyleImage | Yes | Yes | Yes | Yes | Yes |
Sintassi
Restituisce la proprietà listStyleImage:
object.style.listStyleImage
Imposta la proprietà listStyleImage:
object.style.listStyleImage = "none|url|initial|inherit"
Valori di proprietà
Value | Description |
---|---|
none | No image will be displayed. This is default |
url | Specifies the path to the image |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Dettagli tecnici
Valore di default: | nessuno |
---|---|
Valore di ritorno: | Una stringa, che rappresenta il percorso di posizione dell'immagine |
Versione CSS | CSS1 |
Altri esempi
Esempio
Restituisce il valore della proprietà list-style-image:
alert(document.getElementById("myList").style.listStyleImage);
Pagine correlate
Tutorial CSS: Elenco CSS
Riferimento CSS: proprietà list-style-image
Riferimento HTML DOM: proprietà listStyle
❮ Oggetto stile