Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/274.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
jquery表排序_Jquery - Fatal编程技术网

jquery表排序

jquery表排序,jquery,Jquery,我已经动态创建了一个表。该表从数据库中加载数据。这是下面的代码 $('#artistinfo').empty(); $('#artistinfo').append('<table id="transactions" class="partner" width="100%" cellpadding="0" cellspacing="0" style="font-size:90%;" />'); $('#artistinfo table').append( ' <tr class

我已经动态创建了一个表。该表从数据库中加载数据。这是下面的代码

$('#artistinfo').empty();
$('#artistinfo').append('<table  id="transactions" class="partner" width="100%" cellpadding="0" cellspacing="0" style="font-size:90%;" />');
$('#artistinfo table').append(
' <tr class="thead"><th valign="top">Artist</th><th valign="top">Release</th> <th valign="top">Score</th>  </tr>');
$('#artistinfo table').append('<tr>' +
'<td>' + artistname + '</td>' +
'<td>' + releasename + '</td>' +
'<td>' + score+ '</td>' +
'</tr>'
);
我想按每一列把桌子分类。通过jquery可以吗


例如,分数是一种数字类型。我想只使用jQuery对它进行升序或desc排序,因为这个功能不是默认的,所以做你想做的事情会很昂贵。我不会重新发明轮子,而是浏览这些插件:和。这两个提供了相当好的API和广泛的功能,似乎它们也是为了提供良好的性能而设计的


当然,有更多的插件可以显示网格,你可以试试谷歌。

你尝试过什么?我可以帮你用谷歌搜索,第一次点击告诉我sollution是一个流行的插件