I want to do something like this:
$(document).on("pagebeforeshow", "#myPage", function(event){
if(condition){
//I need to do something here to stop loading "myPage"
???
$.mobile.changePage("example.jsp");
}
else {
//continue showing actual page normally
...
}
});
I didn't found any way to change to "example.jsp" page without showing "myPage" for like a second. Is there any way to do that? I tried using things like window.stop()
and event.stopPropagation()
but it doesn't work.
Thank you!