有幾種方法來切換頁面
1.$.mobile.changePage("../path/to/page.html");
2.$.mobile.changePage("other/page.html","fade",false,false);
可以設定頁面切換效果,以及定義引數來控制頁面是否記錄歷史等
3.varpageData={url:formresults.php,type:"get",data:
$("form#myform").serialize()};
$.mobile.changePage(pageData);
將頁面url,型別,資料定義為變數來傳遞。4.
varpreviousPage=$.mobile.activePage.data("ui.prevPage");
$.mobile.changePage([previousPage,anotherPreviousPage],"pop");
使用changepage來載入第三個頁面
5.$.mobile.pageLoading();/顯示載入資訊
$.mobile.pageLoading(true);//隱藏
pageLoading(booleandone)
函式顯示或隱藏頁面載入的提示資訊。可以在$.mobile.loadingMessage變數中設定。
6.$.mobile.silentScroll(100);
silentScroll(numberyPos):在Y軸上(預設為0)滾動頁面而不需要觸發scroll事件
有幾種方法來切換頁面
1.$.mobile.changePage("../path/to/page.html");
2.$.mobile.changePage("other/page.html","fade",false,false);
可以設定頁面切換效果,以及定義引數來控制頁面是否記錄歷史等
3.varpageData={url:formresults.php,type:"get",data:
$("form#myform").serialize()};
$.mobile.changePage(pageData);
將頁面url,型別,資料定義為變數來傳遞。4.
varpreviousPage=$.mobile.activePage.data("ui.prevPage");
$.mobile.changePage([previousPage,anotherPreviousPage],"pop");
使用changepage來載入第三個頁面
5.$.mobile.pageLoading();/顯示載入資訊
$.mobile.pageLoading(true);//隱藏
pageLoading(booleandone)
函式顯示或隱藏頁面載入的提示資訊。可以在$.mobile.loadingMessage變數中設定。
6.$.mobile.silentScroll(100);
silentScroll(numberyPos):在Y軸上(預設為0)滾動頁面而不需要觸發scroll事件