I received complaints from some customers that the site was not completing the request, but checking the code did not find anything too much and it works perfectly for me. The ajax code is this
$.ajax({
type : 'POST',
url : 'www.site.com/functions.php',
data : {func: func, nome: nome, email: email, cel: cel, tamanho: tamanho, modelo: modelo, valor: valor},
dataType : 'json',
timeout : 30000,
cache: false,
beforeSend: function(){
$('div.loading').fadeIn(400);
},
complete: function(response){
$('div.loading').fadeOut(400);
avancar_container(id);
alert(response);
},
success: function(response){
$('div.loading').fadeOut(400);
avancar_container(id);
alert(response);
},
error: function(response){
alert(response);
}
});
The strange thing is that the request is registered in the database, which discards me error in php, however the person does not receive the message of success.