[Main Site Page: Freeing the Mind]
[Cascading Style Sheets: Contents]
[Previous: Declarations]
[This Page: Headings]
[Next: Alignment]
We can control which font is used for heading by specifying the font for the heading selectors.
There are 4 standard fonts:
They are illustrated below along with the examples of the Headings.
Our code is:
H1,H2,H3,H4 {font-family: serif;colour:#0000ff}
I am a paragraph, so I have default properties (whatever they are on your computer!) Unlike properties for the body, the properties for elements, such as the headings do not affect the properties of other parts of the document.
My code is:
H1 {font-family: sans-serif}
My code is:
H1 {font-family: cursive}