如何将div标签停靠在页脚 [英] how to dock a div tag to footer

查看:111
本文介绍了如何将div标签停靠在页脚的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的div,我希望它停靠在页面的底部.

it s my div i want it docked to foot of page.

<div>
     <div id="Footer">
</div>
</div>

推荐答案

尝试使用此方法可能会有所帮助
CSS文件
-------------
Try this one may helps
css file
-------------
* {
margin: 0;
}
html, body {
height: 100%;
}
.wrapper {
min-height: 100%;
height: auto !important;
height: 100%;
margin: 0 auto -4em;
}
.footer, .push {
height: 4em;
}



您的页面
-----------



Your page
-----------

<html>
    <head>
        <link rel="stylesheet" href="layout.css" ... />
    </head>
    <body>
        <div class="wrapper">
            <p>Your website content here.</p>
            <div class="push"></div>
        </div>
        <div class="footer">
            <p>Copyright (c) 2008</p>
        </div>
    </body>
</html>


这篇关于如何将div标签停靠在页脚的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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