Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在制作这个页面,它有一个粘性页脚。
内容 div 正在通过粘性页脚,并且由于绝对定位,我无法overflow:hidden;正常工作。
overflow:hidden;
谁能帮我 ?
请不要对设计发表评论:P 也不是我的一杯茶。
链接到网站| 链接到 jsfiddle 示例
将以下 CSS 添加到页脚
position: fixed; bottom: 0; width: 100%
首先,把你#footer的#wrapper.
#footer
#wrapper
#wrapper { min-height: 100%; overflow-y: hidden; } #footer { position: absolute; bottom: 0; z-index: 1; } #main { z-index: 0; }