我确信我只是遗漏了一些基本的东西,但任何人都可以看到以下代码有什么问题吗?当我单击第一个按钮时,它不会打开弹出窗口.第二个按钮将弹出窗口作为对话框打开.
最佳答案
确实,这是你遗失的一件小事! =)
原文链接:https://www.f2er.com/html/426473.htmljQuery 1.3 Mobile Pop-up Docs:
…then create a link with the href set to the id of the popup div,and add the attribute data-rel=”popup” to tell the framework to open the popup when the link is tapped. This is a similar markup pattern to the dialog widget. A popup div has to be nested inside the same page as the link.
移动< div id =“menu-items”>< / div>在< div id =“home”data-role =“page”>< div>内节点,那应该是它!