Area target Proprietà
Esempio
Cambia il target per un'area specifica in una mappa immagine:
document.getElementById("venus").target = "_blank";
Definizione e utilizzo
La proprietà target imposta o restituisce il valore dell'attributo target di un'area.
L'attributo target specifica dove aprire il documento collegato.
Supporto del browser
Property | |||||
---|---|---|---|---|---|
target | Yes | Yes | Yes | Yes | Yes |
Sintassi
Restituisce la proprietà di destinazione:
areaObject.target
Imposta la proprietà di destinazione:
areaObject.target = "_blank|_self|_parent|_top|framename"
Value | Description |
---|---|
_blank | Open the linked document in a new window |
_self | Open the linked document in the same frame as it was clicked (this is default) |
_parent | Open the linked document in the parent frameset |
_top | Open the linked document in the full body of the window |
framename | Open the linked document in a named frame |
Dettagli tecnici
Valore di ritorno: | Una stringa, che rappresenta dove aprire il documento collegato |
---|
Altri esempi
Esempio
Ottieni il target di un'area specifica in una mappa immagine:
var x =
document.getElementById("venus").target;
Pagine correlate
Riferimento HTML: attributo di destinazione HTML <area>
❮ Oggetto Area