Name

<FONT> — NN all IE all HTML 3.2

Synopsis

<FONT>...</FONT>

End Tag: Required

A FONT element is a container whose contents are rendered with the font characteristics defined by the element’s attributes. This element is deprecated in HTML 4.0 in favor of font attributes available in style sheets that are applied directly to other elements or the artificial SPAN container for inline font changes. This element will be supported for a long time to come to allow backward compatibility with web pages designed for older browsers, however.

The FONT element has evolved over its lifetime, adding new attributes along the way to work in the more mature browsers. Navigator includes some proprietary attributes for Version 4 that are better served by style sheets for cross-browser compatibility.

Example

<FONT FACE="Times, serif" SIZE=4>

Object Model Reference

IE

[window.]document.all.elementID

Attributes

CLASS

FACE

LANGUAGE

SIZE

TITLE

COLOR

ID

POINT-SIZE

STYLE

WEIGHT

DIR

LANG

   

Get Dynamic HTML: The Definitive Reference 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.