<BASEFONT>
Description
Change the appearance of the default font that is used to draw the text. This
element can be specified inside the HEAD or
the BODY of the document. When used in the HEAD it
sets the values for the complete document. When the element is used in the BODY
it affects the text following the element. A next occurrence will again set new
values to be used.
Navigator and Internet Explorer handle this element in the BODY different. In
Navigator the size is reset to the standard value, in Explorer the size is kept
the same. See the example.
The settings do not effect every text of the document. For example, text
inside a table is not affected, and always displayed with the standard font.
The base font size applies to the normal and preformatted text but not to
headings, except where these are modified using the FONT element with a
relative font size.
DTD
Note: This element is deprecated, and this DTD fragment is taken from the
transitional DTD.
<!ELEMENT BASEFONT - O EMPTY -- base font size -->
<!ATTLIST BASEFONT
id ID #IMPLIED -- document-wide unique id --
size CDATA #REQUIRED -- base font size for FONT elements --
color %Color; #IMPLIED -- text color --
face CDATA #IMPLIED -- comma separated list of font names --
>
from the
HTML 4.0 DTD,
"Copyright ©
W3C,
(MIT,
INRIA,
Keio).
All Rights Reserved."
Attributes
ID
Description of the ID attribute
COLOR
Set the default color of the text in the document.
See the page Using colors for a description on
specifying colors.
FACE
Set the default font of the document. You can use the same syntax as with the
FACE attribute of the FONT element.
You can supply more than one name, delimited by a comma. The browser will use
the first font of the list which is available. So when the following statement
<BASEFONT face="Cotton,Arial"> is rendered by the browser and
the font Cotton is installed then this font will be used. If this font is not
installed then Arial is searched.
If none of the supplied fonts are available then the browser will use a default
font.
SIZE
Set the default size of the text in the document. The valid range is 1 - 7. The
default is 3.
When using the FONT element to change the size with a relative value,
eg <FONT size="+2">, the new size is relative to
the size specified here.
To change the font size by 1, the elements BIG and
SMALL can be used instead of the FONT element.
Examples
|
<BASEFONT size="5">
The font is much bigger now.
<BASEFONT color="green">
And set to a green color. Netscape has reset the size now!
<P>
To see the BASEFONT element in action in the HEAD:
<A href="BASEFONT1.html">view this example</A>.
|
|
|
The font is much bigger now.
And set to a green color. Netscape has reset the size now!
To see the BASEFONT element in action in the HEAD:
view this example.
|