【问题标题】:freezing first row and column in bootstrap在引导程序中冻结第一行和第一列
【发布时间】:2015-04-20 13:38:22
【问题描述】:

我在我的应用程序中使用引导程序进行布局。 整个页面被分割成2X2 div,

我想冻结第一行和第一列。我该怎么做?

下面是描述我的要求的图表。

【问题讨论】:

标签: javascript html css twitter-bootstrap


【解决方案1】:

米塔利,试试这个,

使用position:fixed作为第一行

这是左侧框

.leftside {
display: inline-block;
float: left;
position: relative;
width: 250px (your value);
margin-top: 58px (your value);
background-color: #ccc;
height: 100%;
}

右侧框

.rightside {
margin-left: 250px;
min-height: 1000px (your value);
margin-top: 0px;
padding: 0px;
background-color: #eee;
overflow: auto;
position: relative;
}

【讨论】:

    【解决方案2】:

    用 bootstrap 试试这个-

    #sidebar.affix-top{
    position: static;
    margin-top:30px;
    width:228px;
    }
    #sidebar.affix{
    position: fixed;
    top:70px;
    width:228px;
    }
    

    【讨论】:

      【解决方案3】:

      已经有几个例子了。

      https://codepen.io/aifarfa/pen/jbMqba

      https://jsfiddle.net/RMarsh/bzuasLcz/3/

      https://www.jqueryscript.net/demo/jQuery-Plugin-To-Freeze-Table-Columns-Rows-On-Scroll/

      Looks like I have to enter in code to show these links, this is for angular and jquery using html tables.
      

      【讨论】:

        猜你喜欢
        • 2017-12-17
        • 2018-07-09
        • 1970-01-01
        • 2021-07-03
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多