0
我想创建页脚效果,就像在this网站上一样。我想我需要一个包装我的内容,然后添加页脚。在CSS中固定页脚效果(如固定图像)
所以结构会是这样:
<div class="content"></div>
<div class="footer">
<div class="footer-content">
</div>
</div>
和CSS一样:
.footer{
width: 100%;
}
.footer-content{
position: fixed;
bottom: 0;
width: 100%;
z-index: 0;
}
.content{
z-index: 9999 !important;
background-color: #fff;
position: relative;
margin-bottom: 600px; //height of my full footer
}
但是这并没有使这种效果。请帮助并为我的英语感到抱歉。
埃米尔,是对的。另外,你的代码应该可以工作。 – Vcasso
阿米尔发短信关于固定背景图片 - 我想整个页脚固定效果(与内容)。 – Roberto
它非常接近,这里是一个小提琴:https://jsfiddle.net/jrgaoztp/ – deebs