Questa traduzione è incompleta. Collabora alla traduzione di questo articolo dall’originale in lingua inglese.

L' elemento HTML <i> rappresenta un testo distinto dal testo normale per qualche ragione, come nel caso di termini tecnici, stranieri, ecc. E' tipicamente visualizzato in corsivo.

Content categories Flow content, phrasing content, palpable content.
Permitted content Phrasing content.
Tag omission Nessuna, sia il tag di apertura che quello di chiusura sono obbligatori.
Permitted parents Any element that accepts phrasing content.
Permitted ARIA roles Any
DOM interface HTMLElement Up to Gecko 1.9.2 (Firefox 4) inclusive, Firefox implements the HTMLSpanElement interface for this element.

Attributes

Questo elemento include soltanto attributi globali.

Usage Notes

  • Use the <i> element for text that is set off from the normal prose for readability reasons. This would be a range of text with different semantic meaning than the surrounding text.
  • In earlier versions of the HTML specification, the <i> element was merely a presentational element used to display text in italics, much like the <b> element was used to display text in bold letters. This is no longer true, as these tags now define semantics rather than typographic appearance. A browser will typically still display the contents of the <i> element in italic type, but is, by definition, no longer required to.
  • Typically this element is displayed in italic type. However, it should not be used simply to apply italic styling; use the CSS font-style property for that purpose.
  • Be sure the text in question is not actually more appropriate for another element.
    • Use <em> to indicate stress emphasis.
    • Use <strong> to indicate stronger importance.
    • Use <mark> to indicate relevance.
    • Use <cite> to mark the name of a work, such as a book, play, or song.
    • Use <dfn> to mark the defining instance of a term.
  • It is a good idea to use the class attribute to identify why the element is being used, so that if the presentation needs to change at a later date, it can be done selectively with style sheets.

Example

Questo esempio mostra l'uso dell'elemento <i> per contrassegnare il testo di un'altra lingua.

<p>La frase latina <i class="latin">Veni, vidi, vici</i> è spesso menzionata in musica, arte e letteratura.</p>

Result

La frase latina Veni, vidi, vici è spesso menzionata in musica, arte e letteratura.

Specifications

Specification Status Comment
HTML Living Standard
The definition of '<i>' in that specification.
Living Standard  
HTML5
The definition of '<i>' in that specification.
Recommendation  
HTML 4.01 Specification
The definition of '<b>' in that specification.
Recommendation  

Browser compatibility

FeatureChromeEdgeFirefoxInternet ExplorerOperaSafari
Basic support1 Yes1 Yes Yes Yes
FeatureAndroid webviewChrome for AndroidEdge mobileFirefox for AndroidOpera AndroidiOS SafariSamsung Internet
Basic support Yes Yes Yes4 Yes Yes Yes

See also

Tag del documento e collaboratori

Hanno collaborato alla realizzazione di questa pagina: rudijuri
Ultima modifica di: rudijuri,