我有一个像这样的 CSS 盒子模型:
使用 jQuery(单击按钮时)我调整了主要内容 Div 的大小,但页脚没有保持其在屏幕底部的位置:
我尝试将 position: fixed
设置为 footer div,但它不会随页面滚动。
我想知道是否有一种不管内容如何定位页脚的方法
最佳答案
使用css来实现
.my_footer {
position: fixed;
bottom: 0;
left: 0;
right: 0;
height: 100px;
}
关于jquery - 如何设置固定位置到DIV进入页面,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17590836/