0

我有一个 jquerymobile 应用程序,有些页面加载 ajax 网络调用很重,所以我想显示一个对话框。我已经设置好了,但由于某种原因它非常显示。所以看起来页面只是空的,没有做任何工作。我应该调用 pageinit 函数还是 pageshow?谢谢你的帮助。

 $('#MyAlbums').live('pagebeforeshow', function (event) {
             $.mobile.showPageLoadingMsg();
              var myselect = $("select#select-choice-1");
              myselect[0].selectedIndex = 0;
              myselect.selectmenu("refresh");
            GetMyAlbumInformation('full');
        });
4

1 回答 1

1
$(document).bind('mobileinit', function(){
  $('#MyAlbums').live('pagebeforeshow', function (event) {
    $.mobile.loadingMessage= ' The message I want to display ';
    $.mobile.showPageLoadingMsg();
    var myselect = $("select#select-choice-1");
    myselect[0].selectedIndex = 0;
    myselect.selectmenu("refresh");
    GetMyAlbumInformation('full');
   });
});
于 2012-07-28T14:43:21.663 回答