| CSS Declaration | Output |
|
p {background-color: 00FF00;}
| Green Background
|
|
p {background-color: red;}
|
Red Background
|
| CSS Declaration | Output |
|
p {background-image:url(yp.jpg);}
| With Background Image
|
| CSS Declaration | Output |
|
p {
background-image:url(yp.jpg);
background-repeat: no-repeat;
}
| Background does not repeat.
|
|
p {
background-image:url(yp.jpg);
background-repeat: repeat-x;
}
| Background repeats horizontally.
|
|
p {
background-image:url(yp.jpg);
background-repeat: repeat-y;
}
| Background repeats vertically.
|
|
p {
background-image:url(yp.jpg);
background-repeat: repeat;
}
| Background repeats in both directions.
|