Multiple ajax datatables on one page won't load on Firefox

Multiple ajax datatables on one page won't load on Firefox

majodmajod Posts: 4Questions: 0Answers: 0
edited November 2012 in DataTables 1.9
Hello,

I am using datatables 1.9.4 and have multiple datatables on one page using this code:

[code]$('#clienttable').dataTable({
"bProcessing": true,
"bServerSide": true,
"sDom": '<"top"fp>rt<"bottom"pi><"clear">',
"sPaginationType": "full_numbers",
"bLengthChange" : false,
"aoColumns": [{"sWidth":"20%"},{"sWidth":"20%"},{"sWidth":"20%"},{"sWidth":"20%"}],
"iDisplayLength" : 10,
"aaSorting": [[0,"asc"]],
"fnCreatedRow" : function( nRow, aData, iDataIndex ) {
$('td',nRow).addClass('tablecellu');
},
"sAjaxSource": "datatables_dashboard_clients.php"
}).fnSetFilteringDelay();

$('#familytable').dataTable({
"bProcessing": true,
"bServerSide": true,
"sDom": '<"top"fp>rt<"bottom"pi><"clear">',
"sPaginationType": "full_numbers",
"bLengthChange" : false,
"aoColumns": [{"sWidth":"20%"},{"sWidth":"20%"}],
"iDisplayLength" : 10,
"aaSorting": [[0,"asc"]],
"fnCreatedRow" : function( nRow, aData, iDataIndex ) {
$('td',nRow).addClass('tablecellu');
},
"sAjaxSource": "datatables_dashboard_family.php"
}).fnSetFilteringDelay();
[/code]

As you can see both tables are using different ajax sources. But what is happening when I load the page is in Firefox I always get an error from one of the tables:

"DataTables warning (table id = 'familytable'): DataTables warning: JSON data from server could not be parsed. This is caused by a JSON formatting error"

There is absolutely no error in the data,because when I remove one of the datatables, the other one is always working. And also - both of the datatables are working perfectely on every browser, except Firefox. It's only Firefox which gives me this error (I tried Firefox 17 and 15), chrome and IE works fine with both of the tables. Any way to fix this?

Thank you.

Replies

  • allanallan Posts: 63,394Questions: 1Answers: 10,450 Site admin
    Should work okay. Can you link us to a test page showing the issue so we can debug it please.
This discussion has been closed.