Font styles and phrases

A number of XHTML elements are used to format the content of text blocks.

Styles

The Bold (B) element specifies a bold typeface, and the Italic (I) element specifies an italic typeface. They may be nested to create combination styles:

<P>This paragraph contains <B>bold</B>,
<I>italic</I> and <B><I>bold/italic</I></B> text.</P>

   This paragraph contains bold, italic and bold/italic text.

The Teletype (Tt) element specifies a monospaced font, such as Courier.

The Big and Small elements are complementary. They specify larger and smaller text respectively, but the actual size is determined by the browser.

Phrase styles

The Abbreviation (Abbr) element is used to identify an abbreviation in the text:

 The term <abbr>Web</abbr> ...

Get XML Companion, The, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.