jQuery mobile pagecontainer load()

浪子不回头ぞ 提交于 2019-12-11 19:53:30

问题


What does this code do?

$(":mobile-pagecontainer").pagecontainer("load", "#welcome2");

I have a jQuery UI autocomplete input box which I initialize, but it only works if any of the following is true:

  • I call load on the fragment.
  • The visitor starts on #welcome2 (rather than coming from #welcome1)

I don't understand what load does or why I need it.

EDIT: Could it be something with the order in which jQuery UI and jQuery mobile are loaded?

EDIT2: It seems no widgets on not-loaded fragment are initialized. I can't even do things like .checkboxradio("disable") unless the fragment has been explicitly loaded. what does loading mean and why isn't it done when the document is loaded?

来源:https://stackoverflow.com/questions/24976793/jquery-mobile-pagecontainer-load

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!