我想要一个 html 页面,它有一个 html 标题和一个具有不可滚动功能的表标题。只有表格内容应该是可滚动的。
例如:
<html>
<body>
<h1>header</h1>
<h1>header2</h1>
<table>
<thead>
<tr>
<th>name</th>
</tr>
<tr>
<th>address</th>
</tr>
</thead>
<tbody>
<tr>
<td>Venkat</td>
</tr>
<tr>
<td>bangalore</td>
</tr>
//this part will be repeating
</tbody>
</table>
</body>
</html>
我只希望表体中的内容可以滚动。
我也提到了以下链接 How do you create non scrolling div at the top of an HTML page without two sets of scroll bars
但我不能使用 div 只包含标题和表头..
我创建了一个与我的情况类似的 fiddle 。请看http://jsfiddle.net/VenkateshManohar/bU7NN/
最佳答案
你会找到一个 jQuery 插件 here那会为你做的;)
关于html - 带有表格标题的不可滚动的 HTML 内容,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22834192/