alt

The alt element provides an element equivalent of the alt attribute on the image element. As an element, it provides direct text entry within an XML editor and is more easily accessed than an attribute for translation.

The use of the alt attribute is deprecated but still supported. The alt element is the preferred way of indicating alternative text for an image.

Contains

( text data or keyword or option or parmname or apiname or cmdname or msgnum or varname or wintitle or term) (any number)

Contained by

image

Inheritance

topic/alt

Attributes

Name Description Data Type Default Value Required?
%univ-atts; (%select-atts;, %id-atts;, translate, xml:lang) A set of related attributes, described at univ-atts parameter entity PE not applicable Not applicable
%global-atts; (xtrf, xtrc) A set of related attributes, described at global-atts parameter entity PE not applicable Not applicable
class, outputclass Common attributes described in othercommon

Example

The markup for alt text within an image looks like this:

<image href="tip-ing.jpg"/>
  <alt>Here's a Tip!</alt>
</image>