【发布时间】:2010-12-01 11:49:36
【问题描述】:
是否有任何现有的表格排序库,或者有没有办法配置tablesorter,每两行排序一次?或者,是否有更好的方法来语义表达我的表格,以便标准行排序可以工作。
我有一个看起来像这样的 html 表格
<table>
<thead>
<tr>
<th>Header 1</th>
<th>Header 2</th>
</tr>
</thead>
<tbody>
<tr>
<td>Some Data: 1</td>
<td>Some More Data:1 </td>
</tr>
<tr>
<td colspan="2">Some text about the above data that puts it in context and visually spans under both of the cells above so as not to create a weird looking table</td>
</tr>
<tr>
<td>Some Data: 2</td>
<td>Some More Data: 2</td>
</tr>
<tr>
<td colspan="2">Some text about the above data 2 set that puts it in context and visually spans under both of the cells above so as not to create a weird looking table</td>
</tr>
</tbody>
</table>
我正在寻找一种对表格进行排序的方法,以便表格按数据行排序,但带有 colspan 的行随其数据一起移动,而不是单独排序。 p>
【问题讨论】:
标签: javascript jquery html