Hide "Loading..." message on AJAX error like 403, 404
Hide "Loading..." message on AJAX error like 403, 404
I'm use code like this:
[code]
$('#example').dataTable( {
"sAjaxSource": "xhr.php",
} );
[/code]
But when server return error like 403, 404, i can't found how i can handling this error and hide message "Loading..." or show message for user. May be i must use "fnServerData" property and handling AJAX error in $.ajax, but how when hide "Loading..." message?
Sorry for my English.
Thank you.
[code]
$('#example').dataTable( {
"sAjaxSource": "xhr.php",
} );
[/code]
But when server return error like 403, 404, i can't found how i can handling this error and hide message "Loading..." or show message for user. May be i must use "fnServerData" property and handling AJAX error in $.ajax, but how when hide "Loading..." message?
Sorry for my English.
Thank you.
This discussion has been closed.
Replies
[code]
oSettings.oApi._fnProcessingDisplay( oSettings, false );
[/code]
There is an API method that uses this approach:
http://datatables.net/plug-ins/api#fnProcessingIndicator
Allan
I will definitely try it.
As for me, the logical conclusion the message "Failed to load data" when not using fnServerData, because in IE6-7, some tables are creating very slow, and it is not clear what is actually happening. This would save a lot of time in my tests.