"fnServerParams": function (aoData) {
var sReportType = (jQuery('#report_type').val() == "") ? "Downline" : jQuery('#report_type').val();
var aRankID = (jQuery('#rank_id').val() == null) ? [] : jQuery('#rank_id').val();
aoData.push({
"name": "report_type",
"value": sReportType,
"name": "rankid",
"value": aRankID.join(',')
});
},
aRankID should either be an empty array or populated with the values from a multi select box.
When I first load the page here is what firebug returns.
>>> jQuery('#rank_id').val();
null
After I make some selections here is what it returns.
>>> jQuery('#rank_id').val();
["1", "2", "3"]
I must be missing something because it is causing my ajax page to crash. And I need to use.join because my ajax page is expecting a string.
Any help is appreciated!
Try this: