diff options
Diffstat (limited to 'files/it/web/html/attributes/index.html')
-rw-r--r-- | files/it/web/html/attributes/index.html | 591 |
1 files changed, 0 insertions, 591 deletions
diff --git a/files/it/web/html/attributes/index.html b/files/it/web/html/attributes/index.html deleted file mode 100644 index 2da4139452..0000000000 --- a/files/it/web/html/attributes/index.html +++ /dev/null @@ -1,591 +0,0 @@ ---- -title: Attributi -slug: Web/HTML/Attributes -translation_of: Web/HTML/Attributes -original_slug: Web/HTML/Attributi ---- -<p>Gli elementi in HTML hanno <strong>attributi</strong>; questi sono valori addizionali che configurano l'elemento o modificano in vari modi il suo comportamento.</p> -<h2 id="Lista_degli_attributi">Lista degli attributi</h2> -<table class="standard-table"> - <thead> - <tr> - <th>Nome dell'attributo</th> - <th>Elementi supportati</th> - <th>Descrizione</th> - </tr> - </thead> - <tbody> - <tr> - <td>accept</td> - <td>{{ HTMLElement("form") }}, {{ HTMLElement("input") }}</td> - <td>Lista di tipi che il server accetta, normalmente un file di tipo type.</td> - </tr> - <tr> - <td>accept-charset</td> - <td>{{ HTMLElement("form") }}</td> - <td>Lista delle codifiche di caratteri supportate.</td> - </tr> - <tr> - <td>accesskey</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Definisce una scorciatoia da tastiera per attivare o aggiungere il focus all'elemento.</td> - </tr> - <tr> - <td>action</td> - <td>{{ HTMLElement("form") }}</td> - <td>L' URI di un programma che processa le informazioni inviate per mezzo di un modulo.</td> - </tr> - <tr> - <td>align</td> - <td>{{ HTMLElement("applet") }}, {{ HTMLElement("caption") }}, {{ HTMLElement("col") }}, {{ HTMLElement("colgroup") }}, {{ HTMLElement("hr") }}, {{ HTMLElement("iframe") }}, {{ HTMLElement("img") }}, {{ HTMLElement("table") }}, {{ HTMLElement("tbody") }}, {{ HTMLElement("td") }}, {{ HTMLElement("tfoot") }} , {{ HTMLElement("th") }}, {{ HTMLElement("thead") }}, {{ HTMLElement("tr") }}</td> - <td>Specifica l'allineamento orizzontale dell'elemento.</td> - </tr> - <tr> - <td>alt</td> - <td> - <p>{{ HTMLElement("applet") }}, {{ HTMLElement("area") }}, {{ HTMLElement("img") }}, {{ HTMLElement("input") }}</p> - </td> - <td>Testo alternativo in caso un immagine non possa essere visualizzata.</td> - </tr> - <tr> - <td>async</td> - <td>{{ HTMLElement("script") }}</td> - <td>Indica che lo script deve essere eseguito in modalità asincrona.</td> - </tr> - <tr> - <td>autocomplete</td> - <td>{{ HTMLElement("form") }}, {{ HTMLElement("input") }}</td> - <td>Indica che i controlli in questo modulo possono, di defaut, avere il loro valore completato automaticamente dal browser.</td> - </tr> - <tr> - <td>autofocus</td> - <td>{{ HTMLElement("button") }}, {{ HTMLElement("input") }}, {{ HTMLElement("keygen") }}, {{ HTMLElement("select") }}, {{ HTMLElement("textarea") }}</td> - <td>L'elemento riceve il focus automaticamente dopo il caricamento della pagina.</td> - </tr> - <tr> - <td>autoplay</td> - <td>{{ HTMLElement("audio") }}, {{ HTMLElement("video") }}</td> - <td>L'audio o il video devo partire appena possibile.</td> - </tr> - <tr> - <td>bgcolor</td> - <td>{{ HTMLElement("body") }}, {{ HTMLElement("col") }}, {{ HTMLElement("colgroup") }}, {{ HTMLElement("marquee") }}, {{ HTMLElement("table") }}, {{ HTMLElement("tbody") }}, {{ HTMLElement("tfoot") }}, {{ HTMLElement("td") }}, {{ HTMLElement("th") }}, {{ HTMLElement("tr") }}</td> - <td> - <p>Colore di sottofondo dell'elemento.</p> - <p>Nota: Questo è un attibuto ereditato. Utilizzare la proprietà {{ Cssxref("background-color") }} in sostituzione.</p> - </td> - </tr> - </tbody> - <tbody> - <tr> - <td>border</td> - <td>{{ HTMLElement("img") }}, {{ HTMLElement("object") }}, {{ HTMLElement("table") }}</td> - <td> - <p>La larghezza del bordo.</p> - <p>Nota: Questo è un attributo ereditato. Utilizzare la proprietà CSS {{ Cssxref("border") }} in sostituzione.</p> - </td> - </tr> - <tr> - <td>buffered</td> - <td>{{ HTMLElement("audio") }}, {{ HTMLElement("video") }}</td> - <td>Contiene l'intervallo di tempo del media già bufferizzato.</td> - </tr> - <tr> - <td>challenge</td> - <td>{{ HTMLElement("keygen") }}</td> - <td>Una stringa che viene presentata con la chiave pubblica.</td> - </tr> - <tr> - <td>charset</td> - <td>{{ HTMLElement("meta") }}, {{ HTMLElement("script") }}</td> - <td>Dichiara la codifica di caratteri della pagina o dello script.</td> - </tr> - <tr> - <td>checked</td> - <td>{{ HTMLElement("command") }}, {{ HTMLElement("input") }}</td> - <td>Indica che l'elemento deve essere conrollato al caricamento della pagina.</td> - </tr> - <tr> - <td>cite</td> - <td>{{ HTMLElement("blockquote") }}, {{ HTMLElement("del") }}, {{ HTMLElement("ins") }}, {{ HTMLElement("q") }}</td> - <td>Contiene un URI che punta alla sorgente di quanto citato o modificato.</td> - </tr> - <tr> - <td>class</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Usato spesso con i CSS per modellare elementi con proprietà comuni.</td> - </tr> - <tr> - <td>code</td> - <td>{{ HTMLElement("applet") }}</td> - <td>Specifica l'URL del file class della applet che deve essere caricato ed eseguito.</td> - </tr> - <tr> - <td>codebase</td> - <td>{{ HTMLElement("applet") }}</td> - <td>Questo attibuto fornisce l'URL assoluto o relativo della directory dove il file .class dell'applet referenziata dall'attributo code è memorizzato.</td> - </tr> - <tr> - <td>color</td> - <td>{{ HTMLElement("basefont") }}, {{ HTMLElement("font") }}, {{ HTMLElement("hr") }}</td> - <td> - <p>Questo attributo imposta il colore del testo utilizzando un nome colore o specificando il suo valore in formato esadecimale #RRGGBB.</p> - <p>Note: Questo è un attributo ereditato. Utilizzare la proprietà CSS {{ Cssxref("color") }} in sostituzione.</p> - </td> - </tr> - <tr> - <td>cols</td> - <td>{{ HTMLElement("textarea") }}</td> - <td>Definisce il numero delle colonne in un'area di testo.</td> - </tr> - <tr> - <td>colspan</td> - <td>{{ HTMLElement("td") }}, {{ HTMLElement("th") }}</td> - <td>L'attributo colspan definisce il numero delle colonne nelle quali una cella dovrebbe espandersi.</td> - </tr> - <tr> - <td>content</td> - <td>{{ HTMLElement("meta") }}</td> - <td>Un valore associato con <code>http-equiv</code> o <code>name</code> a seconda del contesto.</td> - </tr> - <tr> - <td>contenteditable</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Indica che il contenuto dell'elemento è editabile.</td> - </tr> - <tr> - <td>contextmenu</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Definisce l'ID di un elemento {{ HTMLElement("menu") }} che servirà come menù contestuale dell'elemento.</td> - </tr> - <tr> - <td>controls</td> - <td>{{ HTMLElement("audio") }}, {{ HTMLElement("video") }}</td> - <td>Indica che il browser deve visualizzare i controlli di playack per l'utente.</td> - </tr> - <tr> - <td>coords</td> - <td>{{ HTMLElement("area") }}</td> - <td>Una serie di valori che specificano le coordinate di un area selezionabile all'interno di una regione.</td> - </tr> - <tr> - <td>data</td> - <td>{{ HTMLElement("object") }}</td> - <td>Specifica l'URL della risorsa.</td> - </tr> - <tr> - <td>datetime</td> - <td>{{ HTMLElement("del") }}, {{ HTMLElement("ins") }}, {{ HTMLElement("time") }}</td> - <td>Indica data e ora associate con l'elemento.</td> - </tr> - <tr> - <td>default</td> - <td>{{ HTMLElement("track") }}</td> - <td>Indica che la traccia deve essere abilitata a meno che le preferenze dell'utente indichino diversamente.</td> - </tr> - <tr> - <td>defer</td> - <td>{{ HTMLElement("script") }}</td> - <td>Indicano che lo script deve essere eseguito dopo che la pagina è stata analizzata.</td> - </tr> - <tr> - <td>dir</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Definisce la direzione del testo. I valori permessi sono ltr (Left-To-Right: da sinistra a destra) or rtl (Right-To-Left: da destra a sinistra)</td> - </tr> - <tr> - <td>dirname</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("textarea") }}</td> - <td> </td> - </tr> - <tr> - <td>disabled</td> - <td>{{ HTMLElement("button") }}, {{ HTMLElement("command") }}, {{ HTMLElement("fieldset") }}, {{ HTMLElement("input") }}, {{ HTMLElement("keygen") }}, {{ HTMLElement("optgroup") }}, {{ HTMLElement("option") }}, {{ HTMLElement("select") }}, {{ HTMLElement("textarea") }}</td> - <td>Indica che l'utente non può interagire con l'elemento.</td> - </tr> - <tr> - <td>download</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}</td> - <td>Indica che il collegamento ipertestuale è da utilizzare per scaricare una risorsa.</td> - </tr> - <tr> - <td>draggable</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Definisce l'elemeno come trascinabile.</td> - </tr> - <tr> - <td>dropzone</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Indica che l'elemento consente l'eliminazione dei contenuti da esso.</td> - </tr> - <tr> - <td>enctype</td> - <td>{{ HTMLElement("form") }}</td> - <td>Definisce il tipo di contenuto dei dati del form quando il <code>method</code> è POST.</td> - </tr> - <tr> - <td>for</td> - <td>{{ HTMLElement("label") }}, {{ HTMLElement("output") }}</td> - <td>Descrive elementi che appartengono a questo.</td> - </tr> - <tr> - <td>form</td> - <td>{{ HTMLElement("button") }}, {{ HTMLElement("fieldset") }}, {{ HTMLElement("input") }}, {{ HTMLElement("keygen") }}, {{ HTMLElement("label") }}, {{ HTMLElement("meter") }}, {{ HTMLElement("object") }}, {{ HTMLElement("output") }}, {{ HTMLElement("progress") }}, {{ HTMLElement("select") }}, {{ HTMLElement("textarea") }}</td> - <td>Indicano il form al quale l'elemento si riferisce.</td> - </tr> - <tr> - <td>headers</td> - <td>{{ HTMLElement("td") }}, {{ HTMLElement("th") }}</td> - <td>L'ID che gli elementi <code><th></code> applicano a quest'ultimi.</td> - </tr> - <tr> - <td>height</td> - <td>{{ HTMLElement("canvas") }}, {{ HTMLElement("embed") }}, {{ HTMLElement("iframe") }}, {{ HTMLElement("img") }}, {{ HTMLElement("input") }}, {{ HTMLElement("object") }}, {{ HTMLElement("video") }}</td> - <td>Note: In qualche caso, come per {{ HTMLElement("div") }}, questo attributo è ereditato, e quindi deve essere usata la proprietà CSS {{ Cssxref("height") }} in sostituzione. In altri casi, come per {{ HTMLElement("canvas") }}, l'altezza deve essere specificata con questo attributo.</td> - </tr> - </tbody> - <tbody> - <tr> - <td>hidden</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Global attribute</a></td> - <td>Indica la rilevanza di un elemento.</td> - </tr> - <tr> - <td>high</td> - <td>{{ HTMLElement("meter") }}</td> - <td>Indica il limite inferiore del range superiore</td> - </tr> - <tr> - <td>href</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}, {{ HTMLElement("base") }}, {{ HTMLElement("link") }}</td> - <td> L'URL di una risorsa collegata.</td> - </tr> - <tr> - <td>hreflang</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}, {{ HTMLElement("link") }}</td> - <td>Specifica la lingua della risorsa collegata.</td> - </tr> - <tr> - <td>http-equiv</td> - <td>{{ HTMLElement("meta") }}</td> - <td> </td> - </tr> - <tr> - <td>icon</td> - <td>{{ HTMLElement("command") }}</td> - <td>Spefifica una figura che rappresenta il comando.</td> - </tr> - <tr> - <td>id</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Spesso utilizzato con CSS per applicare uno stile ad uno specifico elemento. Il valore di questo attributo deve essere unico.</td> - </tr> - <tr> - <td>ismap</td> - <td>{{ HTMLElement("img") }}</td> - <td>Indica che l'immagine è una parte della mappa immagine lato server.</td> - </tr> - <tr> - <td>itemprop</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td> </td> - </tr> - <tr> - <td>keytype</td> - <td>{{ HTMLElement("keygen") }}</td> - <td>Specifica il tipo della chiave da generata.</td> - </tr> - <tr> - <td>kind</td> - <td>{{ HTMLElement("track") }}</td> - <td>Specifica il tipo della traccia di testo.</td> - </tr> - <tr> - <td>label</td> - <td>{{ HTMLElement("track") }}</td> - <td>Specifica un titolo leggibile dall'utente della traccia di testo.</td> - </tr> - <tr> - <td>lang</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Definisce la lingua usata nell'elemento.</td> - </tr> - <tr> - <td>language</td> - <td>{{ HTMLElement("script") }}</td> - <td>Definisce la lingua dello script usato nell'elemento.</td> - </tr> - <tr> - <td>list</td> - <td>{{ HTMLElement("input") }}</td> - <td>Identifica una lista di opzioni predefinite da suggerire all'utente.</td> - </tr> - <tr> - <td>loop</td> - <td>{{ HTMLElement("audio") }}, {{ HTMLElement("bgsound") }}, {{ HTMLElement("marquee") }}, {{ HTMLElement("video") }}</td> - <td>Indica che il media deve essere riprodotto dall'inizio quando terminato.</td> - </tr> - <tr> - <td>low</td> - <td>{{ HTMLElement("meter") }}</td> - <td>Indica il valore limite superiore del campo inferiore.</td> - </tr> - <tr> - <td>manifest</td> - <td>{{ HTMLElement("html") }}</td> - <td><span id="result_box" lang="it"><span class="hps">Specifica l'URL del</span> <span class="hps">manifesto</span> <span class="hps">della cache</span> <span class="hps">del documento</span><span>.</span></span></td> - </tr> - <tr> - <td>max</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("meter") }}, {{ HTMLElement("progress") }}</td> - <td>Indica il valore massimo consentito.</td> - </tr> - <tr> - <td>maxlength</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("textarea") }}</td> - <td>Definisce il numero massimo di caratteri consentiti nell'elemento.</td> - </tr> - <tr> - <td>media</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}, {{ HTMLElement("link") }}, {{ HTMLElement("source") }}, {{ HTMLElement("style") }}</td> - <td>Specifica un suggerimento del media per il quale è stata disegnata la risorsa.</td> - </tr> - <tr> - <td>method</td> - <td>{{ HTMLElement("form") }}</td> - <td>Definisce il metodo HTTP da usare alla sottomissione del form. Può essere GET (default) o POST.</td> - </tr> - <tr> - <td>min</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("meter") }}</td> - <td>Indica il valore minimo consentito.</td> - </tr> - <tr> - <td>multiple</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("select") }}</td> - <td>Indica che possono essere inseriti valori multipi come input ad un tipo <code>email</code> o <code>file</code>.</td> - </tr> - <tr> - <td>name</td> - <td>{{ HTMLElement("button") }}, {{ HTMLElement("form") }}, {{ HTMLElement("fieldset") }}, {{ HTMLElement("iframe") }}, {{ HTMLElement("input") }}, {{ HTMLElement("keygen") }}, {{ HTMLElement("object") }}, {{ HTMLElement("output") }}, {{ HTMLElement("select") }}, {{ HTMLElement("textarea") }}, {{ HTMLElement("map") }}, {{ HTMLElement("meta") }}, {{ HTMLElement("param") }}</td> - <td>Nome dell'elemento. E' ad esempio utilizzato dal server per identificare i campi nel form suttomesso.</td> - </tr> - <tr> - <td>novalidate</td> - <td>{{ HTMLElement("form") }}</td> - <td>Questo attributo indica che il form non deve essere validato alla sottomissione.</td> - </tr> - <tr> - <td>open</td> - <td>{{ HTMLElement("details") }}</td> - <td><span id="result_box" lang="it"><span class="hps">Indica se</span> <span class="hps alt-edited">i dettagli</span> <span class="hps alt-edited">verranno visualizzati</span> <span class="hps alt-edited">al caricamento della pagina</span><span>.</span></span></td> - </tr> - <tr> - <td>optimum</td> - <td>{{ HTMLElement("meter") }}</td> - <td>Indica il valore numerico ottimale.</td> - </tr> - <tr> - <td>pattern</td> - <td>{{ HTMLElement("input") }}</td> - <td>Definisce un'espressione regolare con la quale validare il valore dell'elemento.</td> - </tr> - <tr> - <td>ping</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}</td> - <td> </td> - </tr> - <tr> - <td>placeholder</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("textarea") }}</td> - <td>Fornisce un suggerimento all'utente circa cosa può essere inserito nel campo.</td> - </tr> - <tr> - <td>poster</td> - <td>{{ HTMLElement("video") }}</td> - <td><span id="result_box" lang="it"><span class="hps">Un URL</span> <span class="hps">che indica</span> <span class="hps">un fotogramma</span> <span class="hps alt-edited">da mostrare</span> <span class="hps alt-edited">finché l'utente</span> <span class="hps alt-edited">esegue o</span> <span class="hps">cerca.</span></span></td> - </tr> - <tr> - <td>preload</td> - <td>{{ HTMLElement("audio") }}, {{ HTMLElement("video") }}</td> - <td>Indica se l'intera risorsa, parte di essa o niente deve essere precaricata.</td> - </tr> - <tr> - <td>pubdate</td> - <td>{{ HTMLElement("time") }}</td> - <td>Indica che queste data e ora sono dati dell'elemento progenitore più vicino {{ HTMLElement("article") }}.</td> - </tr> - <tr> - <td>radiogroup</td> - <td>{{ HTMLElement("command") }}</td> - <td> </td> - </tr> - <tr> - <td>readonly</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("textarea") }}</td> - <td>Indica se l'elemento è editabile.</td> - </tr> - <tr> - <td>rel</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}, {{ HTMLElement("link") }}</td> - <td>Specifica la relazione dell'oggetto obbiettivo con l'oggetto di collegamento.</td> - </tr> - <tr> - <td>required</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("select") }}, {{ HTMLElement("textarea") }}</td> - <td><span id="result_box" lang="it"><span class="hps">Indica se questo elemento</span> <span class="hps alt-edited">deve</span> <span class="hps alt-edited">essere compilato</span> <span class="hps">o meno.</span></span></td> - </tr> - <tr> - <td>reversed</td> - <td>{{ HTMLElement("ol") }}</td> - <td><span id="result_box" lang="it"><span class="hps">Indica se</span> <span class="hps">l'elenco</span> <span class="hps">deve essere visualizzato</span> <span class="hps">in ordine</span> <span class="hps">decrescente</span> <span class="hps">anzichè </span><span class="hps">ascendente</span><span>.</span></span></td> - </tr> - <tr> - <td>rows</td> - <td>{{ HTMLElement("textarea") }}</td> - <td>Definisce il numero di righe in area di testo.</td> - </tr> - <tr> - <td>rowspan</td> - <td>{{ HTMLElement("td") }}, {{ HTMLElement("th") }}</td> - <td>Definisce il numero di righe sopra le quali si estende la cella della tabella.</td> - </tr> - <tr> - <td>sandbox</td> - <td>{{ HTMLElement("iframe") }}</td> - <td> </td> - </tr> - <tr> - <td>spellcheck</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td><span id="result_box" lang="it"><span class="hps">Indica se</span> <span class="hps">il controllo ortografico</span> <span class="hps alt-edited">è consentito</span> <span class="hps">per l'elemento</span><span>.</span></span></td> - </tr> - <tr> - <td>scope</td> - <td>{{ HTMLElement("th") }}</td> - <td> </td> - </tr> - <tr> - <td>scoped</td> - <td>{{ HTMLElement("style") }}</td> - <td> </td> - </tr> - <tr> - <td>seamless</td> - <td>{{ HTMLElement("iframe") }}</td> - <td> </td> - </tr> - <tr> - <td>selected</td> - <td>{{ HTMLElement("option") }}</td> - <td>Definisce un valore che sarà selezionato al caricamento della pagina.</td> - </tr> - <tr> - <td>shape</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}</td> - <td> </td> - </tr> - <tr> - <td>size</td> - <td>{{ HTMLElement("input") }}, {{ HTMLElement("select") }}</td> - <td>Definisce la larghezza dell'elemento (in pixel). Se l'attributo <code>type </code>dell'elemento è <code>text</code> o <code>password</code> rappresenta il numero di caratteri.</td> - </tr> - <tr> - <td>sizes</td> - <td>{{ HTMLElement("link") }}</td> - <td> </td> - </tr> - <tr> - <td>span</td> - <td>{{ HTMLElement("col") }}, {{ HTMLElement("colgroup") }}</td> - <td> </td> - </tr> - <tr> - <td>src</td> - <td>{{ HTMLElement("audio") }}, {{ HTMLElement("embed") }}, {{ HTMLElement("iframe") }}, {{ HTMLElement("img") }}, {{ HTMLElement("input") }}, {{ HTMLElement("script") }}, {{ HTMLElement("source") }}, {{ HTMLElement("track") }}, {{ HTMLElement("video") }}</td> - <td>L'URL del contenuto incorporabile.</td> - </tr> - <tr> - <td>srcdoc</td> - <td>{{ HTMLElement("iframe") }}</td> - <td> </td> - </tr> - <tr> - <td>srclang</td> - <td>{{ HTMLElement("track") }}</td> - <td> </td> - </tr> - <tr> - <td>start</td> - <td>{{ HTMLElement("ol") }}</td> - <td>Definisce il primo numero se diverso da 1.</td> - </tr> - <tr> - <td>step</td> - <td>{{ HTMLElement("input") }}</td> - <td> </td> - </tr> - <tr> - <td>style</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Definisce gli stili CSS che sovrasteranno gli stili precedentemente impostati.</td> - </tr> - <tr> - <td>summary</td> - <td>{{ HTMLElement("table") }}</td> - <td> </td> - </tr> - <tr> - <td>tabindex</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Sovrascrive l'ordinamento della tabella impostato di default dal browser e segue quello specificato al posto suo.</td> - </tr> - <tr> - <td>target</td> - <td>{{ HTMLElement("a") }}, {{ HTMLElement("area") }}, {{ HTMLElement("base") }}, {{ HTMLElement("form") }}</td> - <td> </td> - </tr> - <tr> - <td>title</td> - <td><a href="/en/HTML/Global_attributes" title="en/HTML/Global attributes">Attributo globale</a></td> - <td>Testo da visualizzare in un suggerimento quando si passa sopra all'elemento.</td> - </tr> - <tr> - <td>type</td> - <td>{{ HTMLElement("button") }}, {{ HTMLElement("input") }}, {{ HTMLElement("command") }}, {{ HTMLElement("embed") }}, {{ HTMLElement("object") }}, {{ HTMLElement("script") }}, {{ HTMLElement("source") }}, {{ HTMLElement("style") }}, {{ HTMLElement("menu") }}</td> - <td>Definisce il tipo dell'elemento.</td> - </tr> - <tr> - <td>usemap</td> - <td>{{ HTMLElement("img") }}, {{ HTMLElement("input") }}, {{ HTMLElement("object") }}</td> - <td> </td> - </tr> - <tr> - <td>value</td> - <td>{{ HTMLElement("button") }}, {{ HTMLElement("option") }}, {{ HTMLElement("input") }}, {{ HTMLElement("li") }}, {{ HTMLElement("meter") }}, {{ HTMLElement("progress") }}, {{ HTMLElement("param") }}</td> - <td>Definisce un valore di default che verrà visualizzato nell'elemento al caricamento della pagina.</td> - </tr> - <tr> - <td>width</td> - <td>{{ HTMLElement("canvas") }}, {{ HTMLElement("embed") }}, {{ HTMLElement("iframe") }}, {{ HTMLElement("img") }}, {{ HTMLElement("input") }}, {{ HTMLElement("object") }}, {{ HTMLElement("video") }}</td> - <td>Nota: In qualche caso, come per {{ HTMLElement("div") }}, questo è un attributo ereditato, quindi deve essere utilizzata la proprietà CSS {{ Cssxref("width") }} in sostituzione. In altri casi, come per {{ HTMLElement("canvas") }}, la larghezza deve essere specificata con questo attributo.</td> - </tr> - <tr> - <td>wrap</td> - <td>{{ HTMLElement("textarea") }}</td> - <td>Indica se il testo deve essere circondato.</td> - </tr> - </tbody> -</table> -<h2 id="Attributi_di_contenuto_contro_attributi_IDL">Attributi di contenuto contro attributi IDL</h2> -<p>In HTML, molti attributi hanno due facce: l'<strong>attributo di contenuto</strong> e l'<strong>attributo IDL</strong>.</p> -<p>L'attributo del contenuto è quello che viene impostato nel contenuto (il codice HTML) e può essere impostato o ricavato tramite {{domxref("element.setAttribute()")}} o {{domxref("element.getAttribute()")}}. L'attributo di contenuto è sempre una stringa, anche quando il valore aspettato dovrebbe essere un intero. Ad esempio, per impostare il <code>maxlength</code> di un elemento {{HTMLElement("input")}} a 42 usando l'attributo di contenuto, occorre chiamare <code>setAttribute("maxlength", "42")</code> su quell'elemento.</p> -<p>L'attributo IDL è conosciuto anche come proprietà JavaScript. Questi attributi possono essere letti o impostati utilizzando proprietà JavaScript come <code class="moz-txt-verticalline">element.foo</code>. L'attributo IDL utilizzerà sempre (ma potrebbe trasformare) l'attributo di contenuto sottostante per ritornare un valore quando viene richiesto e salverà qualcosa nell'attributo di contenuto quando viene impostato. In altre parole, l'attributo IDL riflette, essenzialmente, l'attributo di contenuto.</p> -<p>Il più delle volte, l'attributo IDL ritornerà i loro valori così come sono realmente utilizzati. Ad esempio, il <code>type</code> di default per gli elementi {{HTMLElement("input")}} è "text", se viene impostato come <code>input.type="foobar"</code>, l'elemento <code><input></code> sarà di tipo testo (nell'apparenza e nel comportamento) ma il valore dell'attributo di contenuto "type" sarà "foobar". Tuttavia, l'attributo IDL <code>type</code> ritornerà la stringa "text".</p> -<p>Gli attributi IDL non sono sempre stringhe; ad esempio, <code>input.maxlength</code> è un numero (un long segnato). Quando viene utilizzato l'attributo IDL, viene letto o impostato il valore del tipo desiderato, quindi <code>input.maxlength</code> ritornerà sempre un numero e quando si imposta <code>input.maxlength</code> ,esso vuole un numero. Se viene passato un altro tipo, sarà automaticamente convertito in numero così come specificato dalle regole Javascript standard per la conversione di tipo.</p> -<p>L'attributo IDL può <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/urls.html#reflecting-content-attributes-in-idl-attributes" title="http://www.whatwg.org/specs/web-apps/current-work/multipage/urls.html#reflecting-content-attributes-in-idl-attributes">riflettere altri tipi</a> come long senza segno, URL, valori booleani, etc. Sfortunatamente, non ci sono regole chiare e il modo con il quale si comportano gli attributi IDL in congiunzione con il loro contenuto corrispondente dipenda dall'attributo stesso. Il più delle volte, seguirà <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/urls.html#reflecting-content-attributes-in-idl-attributes" title="http://www.whatwg.org/specs/web-apps/current-work/multipage/urls.html#reflecting-content-attributes-in-idl-attributes">le norme stabilite nelle specifiche</a>, ma a volte no. Le specifiche HTML tentano di renderlo il più possibile facile per gli sviluppatori, ma per varie ragioni (soprattutto storiche), alcuni attributi si comportano stranamente (<code>select.size</code>, ad esempio) e occorre leggere le specifiche per comprendere esattamente il loro comportamento.</p> -<h2 id="Vedi_anche">Vedi anche</h2> -<ul> - <li><a href="/en-US/docs/HTML/Element" title="/en-US/docs/HTML/Element">Elementi HTML</a></li> -</ul> -<p>{{ languages( { "fr": "fr/HTML/Attributs", "en": "en/HTML/Attributes", "ja": "ja/HTML/Attributes" } ) }}</p> |