The good background makes the site look particularly good.
Instance
-
Well-matched backgrounds and colors
-
A good example of background color and text color makes the text in the page easy to read.
-
Poorly matched backgrounds and colors
-
A bad example of background color and text color makes the text in the page difficult to read.
(You can find more instances at the bottom of this page.) )
Background (backgrounds)
<body> a label with two configuration backgrounds. Backgrounds can make colors or images.
Background color (Bgcolor)
The background color property sets the background to a color. The property value can be a hexadecimal number, an RGB value, or a color name.
bgcolor="#000000"
bgcolor="rgb(0,0,0)"
bgcolor="black"
>
The above code sets the background color to black.
Background (Background)
Background property sets the background as an image. The property value is the URL of the image. If the image size is smaller than the browser window, the image is copied throughout the browser window.
background="clouds.gif"
background="http://www.w3school.com.cn/clouds.gif"
>
The URL can be a relative address, such as the first line of code. You can also make an absolute address, such as the second line of code.
Tip: If you're going to use a background image, you need to remember a few things:
- Whether the background image increases the load time of the page. Tip: Image files should not exceed 10k.
- Whether the background image matches the other images on the page.
- Whether the background image matches the text color in the page.
- Does the image look OK when it's tiled in the page?
- is the attention to the text distracting by the background image?
Basic considerations-Helpful tips:
The background color (bgcolor), background (background), and text properties in the <body> tag have been deprecated in the latest HTML standards (HTML4 and XHTML). These attributes have been removed by the consortium in their recommendation criteria.
You should use cascading style sheets (CSS) to define the layout and display properties of HTML elements.
More examples
-
Strong usability Background Image
-
Examples of background images and text colors make page text easy to read.
-
Strong usability Background Image 2
-
Another example of background image and text color makes page text easy to read.
-
Poor usability background image
-
examples of background images and text colors that make page text difficult to read.