my case is: I'm doing a login and I want to check if the user already exists in the database, it goes well, until it does it 8 times (the user is an email, so you have to write more than 8 times), then the $ method. post stops working.
$(document).ready(function () {
$("#email").on("keyup", function () {
console.log("entro en el keyUp");
$.post("<c:url value='/RegistroLogin'/>", {
datoEmail: $("#email").val()
}, function (respuesta) {
if (respuesta == "true") {
console.log("usuario encontrado");
$("#enUso").html("<p class='bg-danger'>Usuario en uso</p>");
} else {
console.log("usuario no encontrado");
$("#enUso").html("<p class='bg-success'>Usuario disponible</p>");
}
}).fail(function () {
console.log("FALLO");
});
});
});
I am using jsp, servlets and MySQL. I have to say that I BELIEVE that what peta is the browser, since if I run the application with another browser ajax responds perfectly, until the 8th query (again).
It's my first question, if details are missing let me know, thank you very much.