It seems simple but with difficulties, I have two modal
that has to appear in the home after login of the user, I need to appear one and only after the user closes that first appears the second modal. I have the following code:
$(document).ready(function(){
$("#ModalUpdateData").modal("hide");
setTimeout(function(){
if (!Cookies.get("ModalScore")){
$("#ModalScore").modal("show");
Cookies.set("ModalScore", true);
} else {
}
},3000);
setTimeout(function(){
if (!Cookies.get("ModalUpdateData")){
$("#ModalUpdateData").modal("show");
Cookies.set("ModalUpdateData", true);
} else {
}
},3000);
});
What is the best solution for this? I've already tried .on('click')
in the #ModalScore (primeiro modal)
element but in it it has a slide where I click inside it to change the slide and ends up making the other modal appear.