|
|||
Backgrounds |
|||
Everything except margins is considered background |
|||
Background-images may not display in all browsers. Default state of the backgrounds is transparent but they can be filled with color, or images. |
|||
Multiple Backgrounds:You can add multiple background images to the body of a document. The following adds three background images to a page. Each url("image1") creates a new background layer that sits one on top of the other. A value of none, an image with 0 width and height, or an image that fails to download still creates a new layer, but doesn’t show an image. |
|||
Background RepeatDetermines how background-images are tiled
|
|||
Background AttachmentDetermines how the image scrolls with respect to the viewport.
|
|||
Background SizeBy default, images will be whatever size they are by default (the auto value) but you can control the image size in several ways. The values are % and length.body {background-size: 300px 40%;} The first value is the width and the second the height. Negative values are not permitted. |
|||
Background Size
|
|||
|
|||
|