My function to get a spinner to load on page load does not seem to be working.
$('#HomeViewPage_ColleagueLocation').live('pagebeforeshow', function(toPage, fromPage){
$.mobile.showPageLoadingMsg("a", "No spinner", true);
setTimeout("test()", 2000);
GetAllUsersByTeam();
GetAvailableTeams();
$('#colleagueLocationLabel').text(CurrentLocationName);
});
function test(){
alert("works");
}
The page loads fine, and the alert goes off, but i never see the “No spinner” message.
BTW I am using IE9.
Why isnt this working?
changing:
to:
solved it.