Multiple Column Sorting not working
Multiple Column Sorting not working
I'm trying to set the initial display of my table to sort 3 columns (the 7th, 4th, and 0th column). I'm trying to use aaSorting to no avail. Here's the code I'm using.
[code]
$(document).ready(function () {
$('#tblProjects').dataTable({
"sPaginationType": "full_numbers",
"bJQueryUI": true,
"bPaginate": true,
"aaSorting": [[7, 'asc'], [4, 'asc'], [0, 'desc']],
"iDisplayLength": 100
});
[/code]
As far as I can tell it is only sorting the 4th column, and no others. Am I doing something wrong? I can get it to sort correctly if I shift click the columns, but I want it to happen automatically on load.
Thanks!
Sorry if this has been answered, I searched around the forum and could not find anything.
[code]
$(document).ready(function () {
$('#tblProjects').dataTable({
"sPaginationType": "full_numbers",
"bJQueryUI": true,
"bPaginate": true,
"aaSorting": [[7, 'asc'], [4, 'asc'], [0, 'desc']],
"iDisplayLength": 100
});
[/code]
As far as I can tell it is only sorting the 4th column, and no others. Am I doing something wrong? I can get it to sort correctly if I shift click the columns, but I want it to happen automatically on load.
Thanks!
Sorry if this has been answered, I searched around the forum and could not find anything.
This discussion has been closed.
Replies
Allan