HTML » Tags » font

Version: 3.2

Compability: Explorer 4, 5  Netscape 4, 6

Syntax:
<font> ... </font>

The <font> element is deprecated in HTML 4.01.

The <font> tag and all associated attributes are officially deprecated effective with HTML 4.0. Instead, you are now to use style sheets. However, this tag remains in wide use on the Internet and is recognized by all major browsers.

The font tag is used to set the face (type), color, and size of the characters in a text.
 
The closing tag is mandatory.
 

Examples

Code:
<font face="arial, helvetica" color="red" size="1">1</font>
<font face="arial, helvetica" color="red" size="2">2</font>
<font face="arial, helvetica" color="red" size="3">3</font>
<font face="arial, helvetica" color="red" size="4">4</font>
<font face="arial, helvetica" color="red" size="5">5</font>
<font face="arial, helvetica" color="red" size="6">6</font>
<font face="arial, helvetica" color="red" size="7">7</font>
<p>
<font face="arial, helvetica" color="red" size="5">c</font>
<font face="arial, helvetica" color="orange" size="5">c</font>
<font face="arial, helvetica" color="yellow" size="5">c</font>
<font face="arial, helvetica" color="green" size="5">c</font>
<font face="arial, helvetica" color="blue" size="5">c</font>
<font face="arial, helvetica" color="purple" size="5">c</font>
<font face="arial, helvetica" color="brown" size="5">c</font>
<p>
<font face="arial">Arial </font>
<font face="courier">Courier </font>
<font face="helvetica">helvetica </font>
<font face="palatino">Palatino </font>
<font face="symbol">Symbol </font>
<font face="times">Times </font>
Output:
1234567
 
ccccccc
 
Arial Courier helvetica Palatino Symbol Times
Language(s): HTML

See Also: