解决方法
您当前的代码:
$('table').dataTable({ // display everything "iDisplayLength": -1 });
你可以做什么
oTable = $('table').dataTable({ // display everything "iDisplayLength": -1 }); oTable.fnSort( [ [0,'desc'] ] ); // Sort by first column descending
$('table').dataTable({ // display everything "iDisplayLength": -1,"aaSorting": [[ 0,"desc" ]] // Sort by first column descending });