The background-position property specifies the position of the background. The values can be
- A combination of [top,center,bottom] and [left,center,right].
- Two percentage values: The first value indicates the horizontal percentage, and the second value indicates the vertical percentage.
- Two position values: The first value is the absolute horizontal position, the second value is the vertical position.
Examples below:
body { background-image: url("yp.jpg");
background-repeat: no-repeat;
background-position: center center;
}
|
body { background-image: url("yp.jpg");
background-repeat: no-repeat;
background-position: 20% 20%;
}
|
|
|
|
Next: CSS Background-Repeat
Link to this page: If you find this page useful, we encourage you to link to this page. Simply copy and paste the code below to your website, blog, or profile.
More Tutorials: SQL PHP HTML
Copyright 2007-2009 1keydata.com All Rights Reserved. Privacy Policy
|
|