• ie6 fixed 实现


     
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
     
      <head>
        <meta charset="utf-8"/>
        <title>CSS Position Fixed for IE6</title>
        <style>
    .fixed-top    {position:fixed;bottom:auto;top:0px;}
    .fixed-bottom {position:fixed;bottom:0px;top:auto;}
     .fixed-right {position:fixed;right:0px;top:0;}
    
    * html,* html body   {background-image:url(about:blank);background-attachment:fixed;}
    
    
    * html .fixed-top           {position:absolute;bottom:auto;top:expression(eval(document.documentElement.scrollTop));}
    * html .fixed-right  {position:absolute;right:0;top:expression( eval(document.documentElement.scrollTop));}
    * html .fixed-bottom       {position:absolute;bottom:auto;top:expression(eval(document.documentElement.scrollTop+document.documentElement.clientHeight-this.offsetHeight-(parseInt(this.currentStyle.marginTop,10)||0)-(parseInt(this.currentStyle.marginBottom,10)||0)));}
     
    
    .fixed-bottom  {
      position:fixed;
      bottom:20px;
      background:blue;
      200px;
      height:200px;
    }
    .fixed-top  {
      position:fixed;
      
      background:blue;
      200px;
      height:200px;
    }
    .fixed-right  {
      position:fixed;
      bottom:20px;
      background:blue;
      200px;
      height:200px;
    }
        </style>
    
      </head>
      <body>
        <div class="fixed-bottom ">ok1</div>
    	 <div class="fixed-top">ok2</div>
    	 <div class="fixed-right"></div>
    <div style="height:1000px;"></div>
        </pre>
      </body>
    </html>
    
  • 相关阅读:
    sweetalert 1.0多次回调函数bug
    ThinkPHP添加扩展配置失败
    记一次相机内存卡数据恢复
    流量监控脚本监控网卡
    ip网关配置
    centos7【防火墙】常用规则-docker服务防火墙规则
    ssh服务及安全配置
    代码库
    linux计划任务防暴力破解脚本+免密操作
    阿里去短信接口包
  • 原文地址:https://www.cnblogs.com/oneroom/p/fixed.html
Copyright © 2020-2023  润新知