zoukankan      html  css  js  c++  java
  • css方法实现div固定浏览器底端

    CSS:

    body{ margin:0; padding:0;background-image:url(text.txt);/*for IE6 防抖,也可以用一张图片URL*/
     background-attachment:fixed;} /*是否存在这文件无所谓,要fixed,不能用scroll */  
    .main{ height:1800px;}
    .footer{ color:red; left:0;background:#ccc; height:30px; position:fixed; bottom:0; z-index:999;  overflow:visible;
    /* for IE6 */
     _top: expression(documentElement.scrollTop + documentElement.clientHeight-this.offsetHeight);
     _position:absolute;
     /* for IE6 */}

    body:

    <div class="main">这是内容层</div>
    <div class="footer">我在底部</div>
    

      

  • 相关阅读:
    LeetCode OJ
    LeetCode OJ
    LeetCode OJ
    linux tips
    vim more
    vim basic
    cut
    paste
    uniq
    Linux的用户
  • 原文地址:https://www.cnblogs.com/tinyphp/p/3159353.html
Copyright © 2011-2022 走看看