FANDOM



The HTML <pre></pre> element is used to display preformatted text in a box-like area, which shows all the source code without having them being applied.

Attribute

Attribute Value Description
width number Uses a number value (80, 132, etc) to give the maximum number of characters which will be displayed on a single line.
Global Attributes

See Global HTML Attributes.


HTML example:

<pre>
Preformatted text. HTML elements do not work, like <b>bolded</b> text, <span style="text-decoration:blink;">blinking text</span>, etc.
</pre>

which produces:

Preformatted text. HTML elements do not work, like <b>bolded</b> text, 
<span style="text-decoration:blink;">blinking text</span>, etc.


Image example:

Pre Element

<pre> in Firefox 3.6.10. Note that there is no background color unless specified using CSS.


See Also

External Links

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.