大佬教程收集整理的这篇文章主要介绍了HTML – 粘性页脚和100%高度的内容,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
HTML
<div class="navbar navbar-inverse navbar-fixed-top"></div> <div class="container"> <div class="content-container"> <div class="my_content">Full height ??</div> <div class="push"></div> </div> <div class="footer"></div> </div>
CSS
html,body { height: 100%; overflow: hidden; } body { padding-top: 50px; } .container { overflow-y: auto; overflow-x: hidden; height: 100%; } .content-container { padding-right: 15px; padding-left: 15px; margin-right: auto; margin-left: auto; position: relative; padding-top: 15px; padding-bottom: 15px; min-height: 100%; margin-bottom: -60px; } .footer { position: relative; width: 100%; BACkground-color: red; } .footer,.push { height: 60px; } .my_content { border: 1px dotted; width: 100%; height: 100%; min-height: 200px; min-width: 300px; }
您可以建议使用粘性页脚的任何其他模板.
以上是大佬教程为你收集整理的HTML – 粘性页脚和100%高度的内容全部内容,希望文章能够帮你解决HTML – 粘性页脚和100%高度的内容所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。