0
我正在创建一个动态填充listview的JQuery Mobile web应用程序。JQuery Mobile Listview元素消失
我遇到的问题是我的列表元素没有显示增强的JQuery Mobile外观,所以我添加了$("#landmarksList").listview("refresh");
,他们现在显示正确。
我的问题是当我点击一个行元素的后退按钮时出现以下错误。
Error: cannot call methods on listview prior to initialization; attempted to call method 'refresh'
error (jquery-2.1.1.js, line 250)
(anonymous function) (jquery.mobile-1.4.2.js, line 1013)
each (jquery-2.1.1.js, line 375)
each (jquery-2.1.1.js, line 139)
(anonymous function) (jquery.mobile-1.4.2.js, line 1005)
(anonymous function) (landmarks.js, line 80)
fire (jquery-2.1.1.js, line 3073)
add (jquery-2.1.1.js, line 3119)
ready (jquery-2.1.1.js, line 3352)
assembleRows (landmarks.js, line 72)
页面显示错误:http://jakeserver.com/Apps/BostonLandmarks/B6/landmarks.html
关于这个令人困惑的事情是,它加载正常,没有错误,第一次页面显示,然后显示此错误时,页面正试图返回到第一页。
任何想法?
谢谢。
我试过了,它仍然显示错误。有任何想法吗? –
我已更新问题中的链接。现在,当您单击后退按钮时,列表视图显示为空白。有任何想法吗? –
感谢您的帮助。我解决了我的问题与消失的ListView:http://stackoverflow.com/questions/24221484/jquery-mobile-ui-overlay-hiding-elements –