Definition The background-image property sets an image as the background. Tip: Always set a background-color to be used if the image is una...
Definition
The background-image property sets an image as the background.Tip: Always set a background-color to be used if the image is unavailable.
Inherited: No
JavaScript Syntax
CSS properties can also be dynamically changed with a JavaScript.Scripting Syntax: object.style.backgroundImage="url(stars.gif)"
Example
body { background-image: url(stars.gif); background-color: #000000 } |
Possible Values
Value | Description |
---|---|
url(URL) | The path to an image |
none | Default. No background image |
Goto CSS3 and CSS2 complete reference