【问题标题】:Keep table header (<thead> tag) constant [duplicate]保持表头(<thead> 标签)不变[重复]
【发布时间】:2012-07-13 04:27:05
【问题描述】:

可能重复:
I need my html table's body to scroll and its head to stay put

我有一个表格,希望标签之间的标题在屏幕上保持不变,而其余部分是可滚动的。我怎样才能做到这一点?我尝试使用 iframe,但没有成功。

【问题讨论】:

  • 你试过position: fixed吗?
  • @Inkbug 使用position:fixed时,单元格对齐不正确。

标签: html


【解决方案1】:

你可以试试下面提到的链接

http://encolpe.wordpress.com/2008/05/01/how-to-add-a-fixed-table-header-with-a-vertical-scrollbar-in-content/

这将为您提供在表中创建修复标题的想法

【讨论】:

    猜你喜欢
    • 2012-08-15
    • 1970-01-01
    • 2017-09-23
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-04-26
    • 1970-01-01
    相关资源
    最近更新 更多