CSS页脚定位溢出问题
我的页脚有问题,我确信我错过了一些应该非常明显的东西,但我已经使用它太久了并且没有取得任何进展。
我的问题是内容部分位于页脚下方而不是向下推。
这是两个重叠的对象。
#footer {
margin: -40px auto 0;
z-index: 9999;
border-bottom: none;
width: 75em;
height: 3.333em;
border: .0833em solid #DEDEDE;
-moz-border-radius-topleft:26px;
-moz-border-radius-topright:26px;
-webkit-border-top-left-radius:26px;
-webkit-border-top-right-radius:26px;
-moz-box-shadow:0px 0px 20px #000000;
-webkit-box-shadow:0px 0px 20px #000000;
box-shadow:0px 0px 20px #000000;
}
#middle {
width:75em;
z-index: -1;
margin:0em auto;
padding: 15px 0 1.667em 0;
height: 95%;
position: relative;
background-color: rgba(255, 255, 255, .30);
-moz-border-radius:26px;
-webkit-border-radius:26px;
border-radius:26px;
-moz-box-shadow:0px 0px 20px #000000;
-webkit-box-shadow:0px 0px 20px #000000;
box-shadow:0px 0px 20px #000000;
}
I am having an issue with my footer, I am sure I'm missing something that should be painfully obvious but I've been playing with it for too long and am making no progress.
My issue is that the content section goes underneath my footer instead of pushing it down.
And here are the two objects that are overlapping.
#footer {
margin: -40px auto 0;
z-index: 9999;
border-bottom: none;
width: 75em;
height: 3.333em;
border: .0833em solid #DEDEDE;
-moz-border-radius-topleft:26px;
-moz-border-radius-topright:26px;
-webkit-border-top-left-radius:26px;
-webkit-border-top-right-radius:26px;
-moz-box-shadow:0px 0px 20px #000000;
-webkit-box-shadow:0px 0px 20px #000000;
box-shadow:0px 0px 20px #000000;
}
#middle {
width:75em;
z-index: -1;
margin:0em auto;
padding: 15px 0 1.667em 0;
height: 95%;
position: relative;
background-color: rgba(255, 255, 255, .30);
-moz-border-radius:26px;
-webkit-border-radius:26px;
border-radius:26px;
-moz-box-shadow:0px 0px 20px #000000;
-webkit-box-shadow:0px 0px 20px #000000;
box-shadow:0px 0px 20px #000000;
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果我理解您想要正确执行的操作,那么您正在尝试防止页脚与“中间”元素重叠。
看一下:
如果将其更改为
删除减号,则会将页脚向南移动。您可以调整确切的长度,但我相信这是主要问题,并且经过测试可以将页脚向下移动。
If I understand what you're trying to do properly, you are trying to keep the footer from overlapping the "middle" element.
Take a look at:
If you change this to
Removing the minus sign moves your footer south. You can adjust the exact length, but I believe this was the primary issue, and it tested to work to move the footer down.