zoukankan      html  css  js  c++  java
  • 锁表头

     <div class="lockContainer" style=" 99%;height:80%;overflow-x:hidden;">
    <table  class="formTable" width="100%" >
       <thead>
        <tr>
         <td class="Locked" style="100px;TEXT-ALIGN: center;">
          销售凭证
         </td>
         <td class="Locked" style="150px;TEXT-ALIGN: center;">
          车工号
         </td>
         <td class="Locked" style="100px;TEXT-ALIGN: center;">
          实际结束:执行(日期)
         </td>
         <td class="Locked" style="80px;TEXT-ALIGN: center;">
          订单优先级
         </td>
         
        </tr>
           </thead>
              <tbody>循环内容.............
     </tbody>
                
    </div>

    lockTable.css  内容如下

    .lockContainer{
     overflow: scroll;border: solid 1px #86B9E4;
    }
    .lockTable{
        border-collapse: collapse;
    }
    .lockTable td
    {
     
     position: relative;
     padding: 0.5px;
        border-top: solid 0px #86B9E4;
     border-bottom: solid 1px #86B9E4;
     border-left: solid 0px #86B9E4;
     border-right: solid 1px #86B9E4;
    }

    .lockTable td.Locked /* 水平与垂直方向锁住单元格, 不随鼠标或滚动条移动 */
    {

     z-index: 30; position: relative;
        background-color: #f3f3f3;
     text-align: center;
        border-top: solid 0px #86B9E4;
     border-bottom: solid 1px #86B9E4;
     border-left: solid 0px #86B9E4;
     border-right: solid 1px #86B9E4;
     top: expression(parentNode.parentNode.parentNode.parentNode.scrollTop);
        left: expression(parentNode.parentNode.parentNode.parentNode.scrollLeft);

    }

    .lockTable td.HLocked /* 水平方向锁住单元格 */
    {

     z-index: 10; position: relative;
     background-color: #f3f3f3;
     text-align: center;
        border-top: solid 0px #86B9E4;
     border-bottom: solid 1px #86B9E4;
     border-left: solid 0px #86B9E4;
     border-right: solid 1px #86B9E4;
     left: expression(parentNode.parentNode.parentNode.parentNode.scrollLeft);


    }

    .lockTable td.VLocked /* 垂直方向锁住单元格 */
    {
     z-index: 20; position: relative;
     background-color: #f3f3f3;
     text-align: center;
        border-top: solid 0px #86B9E4;
     border-bottom: solid 1px #86B9E4;
        border-left: solid 0px #86B9E4;
     border-right: solid 1px #86B9E4;
     top: expression(parentNode.parentNode.parentNode.parentNode.scrollTop);
    }

    .topbar
    {
     z-index: 30; position: relative;
     text-align: center;
     top: expression(parentNode.parentNode.parentNode.parentNode.scrollTop);
        left: expression(parentNode.parentNode.parentNode.parentNode.scrollLeft);
    }

  • 相关阅读:
    关于本站点(说明)
    对Python的认识以及以及Python变量简单的数据类型总结
    分享一个Ubuntu16.0.4安装MySQL5.7脚本
    Shell编程之批量安装服务脚本实例剖析
    Shell编程之批量安装服务脚本实例
    Shell编程之while&until循环详解
    Shell编程之case语句实战
    Shell编程之函数用法 (详解)
    Shell编程之if语句实战(详解)
    mongodb 查询语句笔记
  • 原文地址:https://www.cnblogs.com/lishoubin/p/3211315.html
Copyright © 2011-2022 走看看