2014-10-10 34 views
0

我想延长我的页面长度,但我不完全确定如何。截至目前,我在网页上有一张照片。在图片的底部,我想放置另一个。但是,当我在代码中插入一张新图片时,由于级联样式表,它与现有图片重叠。如何通过CSS扩展页面的长度?

.background-pic .number-1 { 
background-image: url('../resources/images/hoth4.jpg'); 
background-repeat: no-repeat; 
background-size: 109%; 
height: 930px; 
position:   fixed; 
width: 100%; 
background-color: white; 
z-index:   1; 
} 

.background-pic .number-2 { 
background-image: url('../resources/images/hoth2.jpg'); 
background-repeat: no-repeat; 
background-size: 109%; 
height: 930px; 
position:   fixed; 
width: 100%; 
background-color: white; 
z-index:   1; 
} 
+0

这是怎么一回事,因为你正在使用'位置:fixed'都是在同一个地方......你可以分享你的标记,你想要的看? – DaniP 2014-10-10 19:38:12

回答

1

删除position:fixed

,并添加

.background-pic [class^=number]{ 
    display:block; 
    clear:both 
}