Requested unknown parameter '0' from the data error w/ empty data array - IE8 only minified
Requested unknown parameter '0' from the data error w/ empty data array - IE8 only minified
joshuasiegal
Posts: 19Questions: 2Answers: 1
Okay, here's a weird one! I'm getting this error:
DataTables warning (table id = 'DataTables_Table_0'): Requested unknown parameter '0' from the data source for row 0
in dT 1.9.3, but only in IE8 and only in cases where I'm sending an empty array as aaData.
also, this is only happening in IE8
also, this is only happening with the *minified* version of the code.
Sorry I can't post a link, this is not a public site.
Here is my column mapping:
[code]
this.filesMap = [
{ oid:'dateUploaded', 'mDataProp':function(source,type,val) {
if (type=="sort") { return deNull(source.modified_time); }
return deNull(utils.RFCFormat(source.modified_time, true));
}, 'sTitle':'Modification Date' },
{ oid:'fileName', 'mDataProp':function(source,type,val) {
var theFolder = source['folder'].replace(/\\/g,'/');
var folderParent = (dType == 'order') ? 'adfolder' : 'campaignfolder' ;
var fileString = '/services/api.php/'+queryHash+'/files/'+folderParent+theFolder+'/'+source.file;
if (type=="sort") { return fileString; }
return ''+theFolder+'/'+source.file+'';
}, 'sTitle':'File Name' },
{ oid:'fileSize', 'mDataProp':function(source,type,val) {
if (type=="sort") {
return source['size_sort'];
}
return source['size'];
}, 'sTitle':'File Size', "sType" : "numeric" }
];
[/code]
deNull is a method that checks for nulls and replaces them. (i know there's sDefaultContent as well)
utils.RFCFormat is a date formatter
However, from what I can tell, none of this even matters, b/c when I send an empty array at dataTables, it shouldn't even need to use mDataProp, it should just tell me that there's no data to display.
Which it does just fine in any browser other than IE8 - or when there's data to display - or when I'm using the unminified version of the same (1.9.3) library. This makes me suspect the IE8 JS engine a bit. I've even tried re-minifying the 1.9.3 source, no luck.
Any thoughts? Much thanks!
DataTables warning (table id = 'DataTables_Table_0'): Requested unknown parameter '0' from the data source for row 0
in dT 1.9.3, but only in IE8 and only in cases where I'm sending an empty array as aaData.
also, this is only happening in IE8
also, this is only happening with the *minified* version of the code.
Sorry I can't post a link, this is not a public site.
Here is my column mapping:
[code]
this.filesMap = [
{ oid:'dateUploaded', 'mDataProp':function(source,type,val) {
if (type=="sort") { return deNull(source.modified_time); }
return deNull(utils.RFCFormat(source.modified_time, true));
}, 'sTitle':'Modification Date' },
{ oid:'fileName', 'mDataProp':function(source,type,val) {
var theFolder = source['folder'].replace(/\\/g,'/');
var folderParent = (dType == 'order') ? 'adfolder' : 'campaignfolder' ;
var fileString = '/services/api.php/'+queryHash+'/files/'+folderParent+theFolder+'/'+source.file;
if (type=="sort") { return fileString; }
return ''+theFolder+'/'+source.file+'';
}, 'sTitle':'File Name' },
{ oid:'fileSize', 'mDataProp':function(source,type,val) {
if (type=="sort") {
return source['size_sort'];
}
return source['size'];
}, 'sTitle':'File Size', "sType" : "numeric" }
];
[/code]
deNull is a method that checks for nulls and replaces them. (i know there's sDefaultContent as well)
utils.RFCFormat is a date formatter
However, from what I can tell, none of this even matters, b/c when I send an empty array at dataTables, it shouldn't even need to use mDataProp, it should just tell me that there's no data to display.
Which it does just fine in any browser other than IE8 - or when there's data to display - or when I'm using the unminified version of the same (1.9.3) library. This makes me suspect the IE8 JS engine a bit. I've even tried re-minifying the 1.9.3 source, no luck.
Any thoughts? Much thanks!
This discussion has been closed.
Replies
Allan