zoukankan      html  css  js  c++  java
  • div始终在底部

    <style type="text/css">
    body{margin:0;padding:0; }

    html,body{height:100%;}
    div{100%;height:100px;background:#fc9;position:absolute;top:100%;margin-top:-100px}
    </style>
    <div></div>

    底部多高它的margin-top 就负多少。保证不留空白。

    $(document).ready(function () {

    var heighth = (document.body.clientHeight - 59);
    $(".container").height(heighth); //= window.screen.height + 'px';
    // alert(window.screen.height);
    })

    <div class="container" style=" ">

    </div>

    <div style=" height:59px"></div>

    #footer {
        position:fixed;
        left:auto;
        right:auto;
        bottom:0;
        _position:absolute;
        _top:expression(document.documentElement.clientHeight + document.documentElement.scrollTop - this.offsetHeight);
        z-index: 1000;
        font-size:11px;
        line-height:28px;
        height:28px;
        background:url(../Office2007/footid_bg.jpg) repeat-x top;
        padding:2px 15px 0 15px;
        970px;
        margin:0 auto;
    }
  • 相关阅读:
    iOS-Core-Animation-Advanced-Techniques(一)
    vue 路由
    Vue 生产环境部署
    vue 单文件组件
    vue 插件
    Vue 混合
    vue 自定义指令
    vue render函数 函数组件化
    vue render函数
    vue 过渡状态
  • 原文地址:https://www.cnblogs.com/annabook/p/5039439.html
Copyright © 2011-2022 走看看