Is that possible to invoke a javascript function in success of datatable ajax call. Here is the code am trying to use,
var oTable = $('#app-config').dataTable(
{
"bAutoWidth": false,
"bDestroy":true,
"bProcessing" : true,
"bServerSide" : true,
"sPaginationType" : "full_numbers",
"sAjaxSource" : url,
"fnServerData" : function(sSource, aoData, fnCallback) {
alert("sSource"+ sSource);
alert("aoData"+ aoData);
$.ajax({
"dataType" : 'json',
"type" : "GET",
"url" : sSource,
"data" : aoData,
"success" : fnCallback
});
}
is it possible to have something like,
success : function(){
//.....code goes here
}
instead of "success" : fnCallback ------> which is last line of AJAX call. In this function I would like to check a value send from server side. Thanks in advance for any help....
FnServerData
as a callback to$.ajax
. What would you like to use instead? – John Dvoraksuccess : function(){ //.....code goes here }
inside this function I gave alert. And I got the alert message properly. but datatable did not load – rajan.tsm