div在窗口底部,而不是页面 [英] div in bottom of window, not page

查看:60
本文介绍了div在窗口底部,而不是页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想要一个div元素,在窗口的底部。像在facebook.com的底部的一个div。或像初始facebook.com的聊天div

I want a div element, in a bottom of window. like a div in bottom page of old facebook.com. or like a chat div of initial facebook.com

推荐答案

您可以使用 position:fixed; bottom:0px 。但不会在IE6中使用。

You can use position: fixed; bottom: 0px. But won't work in IE6.

<style type="text/css">
    #footer { position: fixed; bottom: 0px; }
</style>

<div id="footer">I am at the bottom of the window</div>

这篇关于div在窗口底部,而不是页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆