Home  >  Article  >  Web Front-end  >  Instructions for using the css background-color property

Instructions for using the css background-color property

黄舟
黄舟Original
2017-06-21 11:49:573243browse

Syntax:

background-color : transparent | color

Parameters:
transparent: The background color is transparent
color: Specify the color. See Color Units and Appendix: Color Table

Description:

Sets or retrieves the background color of the object .
The corresponding script feature is backgroundColor. Please see other books I have written.

Example:

p { background-color: silver }
div { background-color: rgb(223,71,177) } 
body { background-color: #98AB6F }
pre { background-color: transparent; }

background-color -- Background color, defines the color of the background

Value: b10fb37415d019cfffa8c4d7366c607f | transparent | inherit

b10fb37415d019cfffa8c4d7366c607f: color representation

transparent: transparent

inherit: inherit

Initial value: transparent

Inheritance: Yes

Applicable to: all elements

background: background.color: color.

The background color corresponds to the foreground color, which is OK Define the color of the background.

Example

body {	background-color:green;}

Define the background of the web page to use green.

The above is the detailed content of Instructions for using the css background-color property. 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