abbr ElementThe abbr element is an inline element declared by the XHTML 1.1 Text Module (Inline Phrasal)
Elements in the Text Module are:span | br (Inline Structural Support Module)em | strong | q | cite | abbr | acronym | code | var | kbd | samp | dfn (Inline Phrasal Support Module)div | p (Block Structural Support Module)h1 - h6 | blockquote | pre | address (Block Phrasal Support Module)
The abbr element is used to indicate that the enclosed text is an abbreviation. The
title attribute can be used to give the full text which
has been abbreviated.
Examples of the use of the abbr element are:
These examples render as follows:
Often, a browser will render text within an abbr with some kind of line underneath, usually
dotted, and will pop up a tooltip containing the full text when the mouse hovers over the element.
No styles have been applied to the example abbr elements above so they are rendered using your
browser's default behaviour. My version of Konqueror (3.5.4) automatically styles abbr as
font-variant:small-caps (but does not place a line beneath the text).
Note: If you need compatibility with Internet Explorer
you should note that the abbr element is
not supported in IE6 and below. A common way to get around this problem is to use the
acronym element instead, even though it is not semantically
correct for all abbreviations. Since IE7 now supports the abbr
element, it is my policy to use the semantically correct element in all cases.
See also the acronym element.
There are no #REQUIRED attributes on the abbr element.
There are no specific attributes declared on the abbr element.
abbr element are listed below:class [ type NMTOKENS ]id [ type ID ]style [ type CDATA ], from the Style Attribute Module (deprecated)title [ type Text ]abbr element, the full text corresponding to the abbreviation should be
specified in the title attribute
(in some user agents this may appear as a "tooltip" when the mouse hovers over the element)xmlns [ type URI - #FIXED 'http://www.w3.org/1999/xhtml' ]dir [ type Enumeration (ltr | rtl) ], from the Bi-directional Text Modulexml:lang [ type LanguageCode ]All attributes in the
Events Attribute Collection
are supported:onclick, ondblclick, onmousedown, onmouseup, onmouseover, onmousemove, onmouseout, onkeypress, onkeydown, onkeyup
abbr element is:
( #PCDATA | Inline.mix )*
See Content Model & Nesting for information about Content Model syntax and Nesting Groups.
abbrabbr, acronym, br, cite, code, dfn, em, kbd, q, samp, span, strong, varabutton, input, label, select, textareaimgb, big, i, small, sub, sup, ttmapnoscript, scriptdel, insbdoobjectrubyabbrabbr, acronym, address, cite, code, dfn, div, em, h1 - h6, kbd, p, pre, q, samp, span, strong, varadd, dt, licaption, td, thbutton, fieldset, label, legendb, big, i, small, sub, sup, ttdel, insbdoobjectrb, rt