0

下面的代码将图像多次显示为 10 个不同的图像,需要它是完整的图像..

<HTML>

<BODY >

<style>
body {background-image:url('back1.jpg');}
</style>

</BODY>
</HTML>
4

4 回答 4

4

像这样的东西一直对我有用。

body {
    background: url(cool-image.jpg) no-repeat center center;
    top:0;
    left:0;
    min-width:100%;
    min-height:100%;
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
   background-size: cover; 
}

</style>
于 2013-04-01T16:58:28.420 回答
2

试试这个...

html { 
  background: url(images/bg.jpg) no-repeat center center fixed; 
  -webkit-background-size: cover;
  -moz-background-size: cover;
  -o-background-size: cover;
  background-size: cover;
}
于 2013-04-01T16:55:48.973 回答
1
<HTML>

<BODY >

<style>
body {background-image:url('back1.jpg');background-repeat:no-repeat;} // add the no repeat 
</style>

</BODY>
</HTML>
于 2013-04-01T16:54:26.680 回答
0
background-repeat: no-repeat;
background-size: cover;
于 2013-04-01T16:56:50.777 回答