HTML <xmp> (Example) Tag
Deprecated: Not Supported in HTML5.
Example
<p>This is <xmp>E XA MP LE</xmp></p>
Meaning
The <xmp> element specifies that the enclosed text is an example.
Note: This deprecated but still widely supported.
Version: HTML 2
Standard Syntax
<xmp>...</xmp>
Browser Support
Status
Global Attributes
The <xmp> element also supports the Global Attributes in HTML.
Event Attributes
The <xmp> element also supports the Event Attributes in HTML.
More Examples
Use <pre> element:
Example
<pre>This text is formatted
exactly
as
it
is
typed.</pre>
Use <code> element:
Example
<p><code>center</code> tag is deprecated by HTML5 version.</p>
By Default CSS Value(s)
Most of the browsers will display the <xmp> element with the following by default value(s)
xmp {
font-family: monospace;
white-space: pre;
display: block;
}