Home  >  Article  >  Web Front-end  >  The difference between css background-image and layer-background-image

The difference between css background-image and layer-background-image

黄舟
黄舟Original
2017-06-21 16:10:202123browse

layer-background-image

Syntax:

layer-background-image : none | url (url)

Parameters:

none: No background image
url: Use an absolute or relative address to specify the background image

Description:

Sets or retrieves the background image of the entire area of ​​the object.

Example:

code { 
position: absolute; 
top: 100px; left: 300px; 
width: 200px; 
border: thin solid black; 
background-image: url("comet.jpg"); 
layer-background-image: url("bb_comet.jpg"); 
}

What is the difference between using css style to set the background-image and layer-background-image of a layer?

The former is the style in the W3C standard, and the latter is just the Netscape browser's own special writing method. It is recommended to move closer to the W3C standard.

Background-image is for the entire web page.
On the web page The layer is set in. If the floating block (not the window), then the background is layer-background-image
To be honest, there is not much difference. It is recommended that you use background-image instead of layer-background-image
It is not very useful
layer-background-image is included below IE6 (IE6) and is not supported!

The above is the detailed content of The difference between css background-image and layer-background-image. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn