HTML and CSS Reference
In-Depth Information
Figure 4-8. Use <code> to present computer-speak
You should use the <code> tag for text that represents computer source
code or other machine-readable content. While the <code> tag usually
just makes text appear in a monospaced font, the implication is that it
is source code, and future browsers may add other display effects. [*]
[*] None of the popular browsers format <code> segments as a text processor might. Rather, use the
<pre> tag in conjunction with <code> to achieve programming code-like display effects.
For example, a programmer's browser might look for <code> segments
and perform some additional text formatting, such as special indentation
of loops and conditional clauses. If the only effect you desire is a mono-
spaced font, use the <tt> tag. If you want to display the programming
code in rigidly formatted monospaced text, use the <pre> tag. [ The <tt>
Tag, 4.5.10 ] [ <pre>, 4.6.5 ]
4.4.5. The <dfn> Tag
Use <dfn> to tag defining instances of special terms or phrases. The pop-
ular browsers typically display <dfn> text in italics. In the future, <dfn>
might assist in creating a document index or glossary.
For example, use the <dfn> tag to introduce a new phrase to the reader:
 
Search WWH ::




Custom Search