之前这样加背景图测出来有的手机浏览器上全屏背景图宽度超过屏幕宽度,比如mate9,oppo X9上
<div class='box'></div>
html,body{
width:100%;
height:100%
}
.box{
width: 100%;
height: 100%;
background: url(a.jpg) no-repeat 0 0 /cover;
}
之后改成这样就没啥问题了
html,body{
width:100%;
height:100%
}
body{
background: url(a.jpg) no-repeat top left;
background-size: cover;
}