| BACKGROUND COLOR |
| An easy, fast-loading way to customize your page without using graphics is to define a background color in your HTML code. |
Some guidelines for choosing colors:
Contrast between background color and foreground text color is the key to legibility.
A light background color with dark text is the most legible combination.
A dark background color often makes text illegible, even when a light text color is used.
Each computing platform and each type of browser displays color differently. Also, viewers can change the default colors for the text and background on their browsers.
Using web-safe colors can help ensure that viewers see the color you want them to see.
Colors are represented by a series of 6 letters and digits enclosed in quotes. To define a background color, use the "BGCOLOR" attribute with the "BODY" tag. In the example below, "FFFFFF" is the hexadecimal code for a white background. It is a good idea to precede the hexadecimal code with a pound sign (#) so that it renders properly in finicky browsers. Some common colors may be referred to by name.
<body bgcolor="#FFFFFF">
<body bgcolor="white">
|
Example:
| Legible background color choice: |
This color combination will work on most monitors and browsers because the background is a pale color that provides maximum contrast between background and text.
To define a background color, use the "bgcolor" attribute with the "body" tag. "FFFFCC" is the hexadecimal code for the pale yellow background on the page.
<body bgcolor="#FFFFCC">
|
| Illegible background color choice: |
|
The red color is a poor choice because the background is overwhelming, and there is a lack of contrast between background and text.
|
The red color is a poor choice because the background is overwhelming, and there is a lack of contrast between background and text.
|
|
|
|