Background image automatically changes CSS
There is a relatively large background image 2000×648
Use css to set it as the background of the page
The CSS is as follows:
body {text-align: left ; font-family:"新宋体"; margin:auto;padding:0;
font-size:12px;color:#0C0C0C; background-color: #FFF;
BACKGROUND:url(../images /bj.gif) no-repeat;background-position: top center;}
Please tell me how to make the background image automatically resize according to the size of the page, and always display the entire image instead of part of it. ?
Reply to discussion (solution)
The image changes with the size of the page,
.css{
width: 100%;
position: absolute ;
margin-right: auto; It seems that the method cannot be implemented, waiting for experts to explain the background implementation method.