ShowPageLoading

ShowPageLoading Message

by nirmaljpatel

HTML

<link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.css">
<div data-role="page">
    <div data-role="header">
        <h1>Page One</h1>
    </div>
    <div data-role="content">
        <input type="button" id="showLoadingT" value="showLoading TRUE" \>
        <input type="button" id="showLoadingF" value="showLoading FALSE" \>
        <input type="button" id="hideLoading" value="hideLoading" \>
    </div>
</div>

JavaScript

$("#showLoadingT").on("click", function(){
    console.log("showLoadingT clicked.");
    $.mobile.showPageLoadingMsg("b",true)
});

$("#showLoadingF").on("click", function(){
    console.log("showLoadingF clicked.");
    $.mobile.showPageLoadingMsg("b","This is only a test",false);
});


$("#hideLoading").on("click", function(){
    console.log("hideLoading clicked.");
    $.mobile.hidePageLoadingMsg();
    });