我被这个问题困住了,无法摆脱这个问题。请帮我。
在我的网页中,我在一个容器 div 中使用了 3 个 div。我试图消除 div 之间不需要的间隙。
- (1)Top bg图片
- (2)中间bg图像
- (3)底部bg图像
我正在尝试调整这 3 个 div,使其看起来像一个 bg 图像。我的中间部分和底部已完全调整,但顶部和中间部分之间有一些间隙,我试图移除但无法移除。
请参考我在此处附加的图像,该图像显示了顶部和中间部分之间的间隙。请参考我用于放置图像的样式表数据。
提前致谢。
#main_container {
background-repeat:no-repeat;
width:645px;
float:left;
padding-bottom:10px;
overflow:hidden;
height:auto;
}
#middle_part {
background-image: url('/DiscoverCenter/images/apps_mid.png');
background-repeat:repeat-y;
width:645px;
padding-bottom:10px;
overflow:hidden;
height:auto;
clear:both;
position:relative;
display: block;
vertical-align: bottom;
}
#top_part {
background-image:url('/DiscoverCenter/images/apps_top.png');
width:645px;
top:0px;
height:47px; /* actual height of the top bg image */
clear:both;
position:relative;
display: block;
vertical-align: bottom;
}
#bottom_part {
background-image:url('/DiscoverCenter/images/apps_btm.png');
width:645px;
height:24px; /* actual height of the bottom bg image */
}