伙计们请帮我解决这个 float 问题。我尝试了不同的方法,但对我来说没有任何效果。
在html文件中,小图片在全局容器中。页脚放在全局容器的正下方。但是现在页脚到了顶部。
这些是我的CSS-
图像的 CSS-
style="margin-top: 25px; margin-right: 48px; float: right;"<br>
style="margin-top: 25px; margin-right: 48px; float: left;"
#footer_container{
width: 900px;
height: 10px;
margin-top: 10px;
padding-bottom: 10px;
position: absolute;
border: solid;
}
#global_body_container{
width: 746px;
position: absolute;
padding-bottom: 10px;
border-color: #c6c8cc;
border-style:dashed;
clear: both;
}
谢谢。
最佳答案
放置在 float 元素的容器上overflow: hidden
。
#global_body_container {
overflow: hidden;
}
关于html - 需要 CSS float 帮助,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6380046/