xmp

Form

<xmp> ... </xmp>

Attributes

attribute default description
none none none

Support

HTML 3.2
Microsoft (MSDN)
[IE3 or later][Firefox 1 or later][Safari 1 or later][Opera 3 or later][Netscape 2 or later]

Explanation

The text enclosed by the xmp tag is displayed as a fixed width font. Inequality sign and linefeed are also displayed directly.

Related Tags

listing, plaintext, pre

Sample Code [Output]

<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=shift_jis">
<title>Sample</title>
</head>
<body>
<h1>Sample</h1>
<xmp>
for (i=0; i<100; i++) {
n = i * i;
printf("%d\n",n);
}
</xmp>
</body>
</html>