Forum
Notifications
Clear all
Topic starter
With CSS 3, now you can stretch background image for a body, div element or other HTML element.
Here are the CSS codes:
html,
body,
div{
width:100%;
height:100%;
position:relative;
background: url(img/bg.jpg) no-repeat center center;
-webkit-background-size:cover; /*for webKit*/
-moz-background-size:cover; /*Mozilla*/
-o-background-size:cover; /*opera*/
background-size:cover; /*generic*/
}
Posted : 04/10/2012 6:37 pm