English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

HTML Reference Manual

Complete List of HTML Tags

HTML: <basefont> face attribute

The face attribute specifies the default font for the text in the document.

 HTML <basefont> tag

Online Example

Specify the default font on the page font:

<!DOCTYPE html>
<html>
<head>
<title>HTML: <basefont> face attribute - Basic Tutorial Website oldtoolbag.com</title>
<basefont face="courier, serif">
</head>
<body>
<h1>This is a heading</h1"
<p>This is a paragraph.</p>/p>
</html>
Test and see ‹/›

Browser Compatibility

IEFirefoxOperaChromeSafari

Only Internet Explorer 9 及更早IE版本支持 face 属性。

and earlier IE versions support the face attribute.

Definition and Usage5 HTML Is not supported. Please use

The face attribute of <basefont> in HTML 4in HTML1Is deprecated.

CSS alternative.

The face attribute of <basefont> in HTML

Compatibility comment 4in HTML1 .0 1It is not recommended to use the face attribute of the basefont element; in XHTML

.0 Strict DTD does not support the face attribute of the basefont element.-CSS syntax (<head> section): <style>body{font/family: courier, serif</

style>

Syntaxfont_family<basefont face=" /"

>

ValueDescription
font_familySpecifies the font for the text. To specify a preference list of several fonts, separate the font names with commas (for example, <basefont face="verdana,arial,sans-serif /)
 HTML <basefont> tag