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

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

黄舟
Release: 2017-06-21 16:10:20
Original
2153 people have browsed it

layer-background-image

Syntax:

layer-background-image : none | url (url)
Copy after login

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"); 
}
Copy after login

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!

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template