帝王谷资源网 Design By www.wdxyy.com

今天这个案例,我们希望footer一直在页面底部,来看看解决方案吧

css

复制代码代码如下:
html, body, #sticker {height: 100%;}
body > #sticker {height: auto; min-height: 100%;}
#stickerCon {padding-bottom: 40px;}
#footer {margin-top:-40px; height: 40px; width: 100%; text-align: center; line-height: 40px; color: #ABA498; font-size: 12px; background: #fafafa; border-top:1px solid #E7E7E7;}

html


复制代码代码如下:
<div id="sticker">
<div id="stickerCon"></div>
</div>
<div id="footer">footer</div>

标签:
纯css,实现,footer,底部

帝王谷资源网 Design By www.wdxyy.com
广告合作:本站广告合作请联系QQ:858582 申请时备注:广告合作(否则不回)
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件! 如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
帝王谷资源网 Design By www.wdxyy.com