
Opening tag : <PRE>
Closing tag: </PRE>
Purpose:
The Preformated text tag is used to display preformated text, without losing the original formating.
Attributes:
Class=class
- Specifies a class of formating from a stylesheet.
Cols=#
- Specifies the maximum number of characters that can be displayed on one line.
Dir=direction
- Useful for languages that are read from right to left.
Event=Javascript
- Allows some javascript to be run from an event to do with the tag.
Id=Name
- Specifies an identifier for the text so it can be referenced or accessed externally.
Lang=language
- Specifies the Language of the preformated text.
Style=style
- Specifies a style to use for the formating of the text, over other styles.
Title=title
- The text can be given a title as well if required.
Width=#
- The maximum number of characters that can be displayed per line.
Wrap
- Wrap the lines, as it is preformated text, the default is not to wrap the text.
Example:
<Pre> The Pre tag preserves white space </Pre>
Related Tags:
-
Back to:
Alphabetical Guide
Guide By Type