In the following situation, my login form is working perfectly on the desktop version, I went to test on android and on ios it does not work and does not give an error in the console ... just wait for the api .. my javascript file
$(function() {
$("#login-form").validate({
rules : {
email : {
required : true,
email : true
},
password : {
required : true,
minlength : 0,
maxlength : 20
}
},
messages : {
email : {
required : 'E-mail do game',
email : 'E-mail do gmae não e valido'
},
password : {
required : 'Senha do game'
}
},
submitHandler: submitForm
});
function submitForm()
{
var data = $("#login-form").serialize();
$.ajax({
type : 'POST',
url : 'http://localhost/api.game/api/auth',
data : data,
beforeSend: function()
{
$("#error").fadeOut();
$("#btn-login").html('<span class="glyphicon glyphicon-transfer"></span> Aguarde logando.');
},
success : function(response) {
if(response.status === true){
$("#btn-login").html('<img src="../img/rolling.gif" /> Logado você vai ser redirecionado');
setTimeout(function(){location.href=response.redirect} , 2000);
}
else{
$("#error").fadeIn(100, function(){
$("#error").html('<div class="alert alert-danger"> <span class="glyphicon glyphicon-info-sign"></span> '+response.msg+' !</div>');
$("#btn-login").html('<span class="glyphicon glyphicon-log-in"></span> Entrar');
});
}
}
});
return false;
}
});
Has anyone ever had this problem? is not returning an error in the console.