I noticed that when I call a function with ajax request, and update a file on the server on the same time, the call will never return, and I don't get 'error' message from ajax error function.
I must mention that I get the error alert on most cases.
Here is my ajax call:
ajax_request = $.ajax({
url: ajax_url+"/"+action,
data: params,
type: 'post',
async: false,
dataType: 'jsonp',
timeout: 6000,
crossDomain: true,
beforeSend: function() {
//...
loaderSearch.show();
},
complete: function(data) {
//...
},
success: function (data) {
//...
},error: function(){
//...
alert('error')
}