我有一个非常大的图像用作背景图像。由于图像非常大,我已将它分成三个图像,可以将图像堆叠在一起。如何排列与背景图像的几个div
我把图像与性质“封面”背景图片:
<div class="screen" id="header1"></div>
<div class="screen" id="header2"></div>
<div class="screen" id="header3"></div>
CSS:
#header1
{
background-color: #000;
width: 100%;
height: 100%;
max-width: 1920px;
max-height: 949px;
background: url('images/bg1_landscape2.png') no-repeat center center;
background-size:cover;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
padding: 0;
margin: 0;
}
#header2
{
background-color: #000;
width: 100%;
max-width: 1920px;
height: 100%;
max-height: 947px;
background: url('images/bg2_landscape2.png') no-repeat center center;
background-size:cover;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;padding: 0;
margin: 0;
}
#header3
{
background-color: #000;
width: 100%;
height: 100%;
max-width: 1920px;
background: url('images/bg3_landscape2.png') no-repeat center center;
background-size:cover;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
padding: 0;
margin: 0;
}
的问题是,在背景图像模式不排队。
无论屏幕有多宽,如何让多个背景图片排列起来?
你可以添加一个[jdfiddle](http://jsfiddle.net/)吗? – Martyn0627
我无法显示图像 - 它们尚未公开。 – LauraNMS
......如果不是公开的,可能是为了举例构成图像并重复该过程,以便我们可以玩弄代码? – Phlume