using bStateSave is causing oSettings.aaSorting to have incorrect value.

using bStateSave is causing oSettings.aaSorting to have incorrect value.

hamid_numjewhamid_numjew Posts: 2Questions: 0Answers: 0
edited June 2013 in DataTables 1.9
Hi

My datatable consists of 5 columns and many rows. I have created my table with the correct way of using thead, tr and th below:

[code]




headers1
headers2
headers3
headers4
headers5



................my data..............
................my data..............
................my data..............
......



some footer data1
some footer data2
some footer data3
some footer data4
some footer data5




[/code]

and here how i initialised my dataTable

[code]

jQuery(document).ready(function() {
var oTable = jQuery('#example').dataTable({
bStateSave: true,
bJQueryUI : true,
bPaginate : true,
sPaginationType: "full_numbers",
aLengthMenu: [[10, 20, 50, 100 , -1], [10, 20, 50, 100, "All"]],
iDisplayLength: 20,
bProcessing: true,
"aaSorting": [[0, 'asc']],
bInfo : false
});
} );
[/code]

My problem is, if I use the above in a single html page everything is fine and I don't get any errors. BUT if I use the above data in a jsp page along with other javascript files, I get the following error.

[code]
oColumn is undefined
for ( j=0, jLen=oColumn.asSorting.length ; j

Replies

  • peartreechrispeartreechris Posts: 1Questions: 0Answers: 0
    I am having the same issue. Firefox 21, dataTables 1.9.4, jquery 1.8.3.

    Any solution or workaround?
  • allanallan Posts: 63,383Questions: 1Answers: 10,449 Site admin
    Can you link me to a test page showing the error please: http://datatables.net/forums/discussion/12899/post-test-cases-when-asking-for-help-please-read ?

    As you can see in this example, state saving of aaSorting should work just fine: http://datatables.net/release-datatables/examples/basic_init/state_save.html

    Allan
This discussion has been closed.