CSS -- Color and background properties


PropriétésValeur
Valeur initialeAppliquée àHéritéevaleur %
'color'<color>
UA specificall elementsouiN/A
'background-color'<color> | transparent
transparentall elementsnoN/A
'background-image'<url> | none
noneall elementsnoN/A
'background-repeat'repeat | repeat-x | repeat-y | no-repeat
repeatall elementsnoN/A
'background-attachement'scroll | fixed
scrollall elementsnoN/A
'background-position'[ <percentage> | <length> ] {1,2} | [ top | center | bottom ] || [ left | center | right ]
0% 0%block-level and replaced elementsnorefered to the size of the element itself
'background'<background-color> || <background-image> || <background-repeat> || <background-attachement> || <background-position>
not defined for shorthand propertiesall elementsnoallowed on <background-position>

color: color
Set the color of the text. Read more about available colors in the Textstyles-chapter.

background: URL(url)|color
Defines the background, either a picture defined by its URL or a color. See the Textstyles-chapter for information about available colors. As you can see, an URL should be written within parentheses.


Christophe Merlet
redfox@redfoxcenter.org
©Tous droits réservés
11 août 1997