你如何在phonegap + jquerymobile上获得对话框弹出窗口

时间:2013-11-16 23:17:50

标签: javascript android jquery html cordova

通过搜索/文档我读到你所要做的就是在调用任何页面时使用data-rel =“dialog”,它应该打开页面作为对话框。我使用手机间隙+ jquery手机为Android构建商店可提交的应用程序(不是网络应用程序)。

点击下面的锚点会将页面打开为常规页面而不是对话框。我做错了什么或不做什么?

     <a href="use_coins.html" data-rel="dialog">Open dialog Box</a>

以下是use_coins.html

的src

    

<div data-role="page" class="my-bg" id="use_coins_dialog">


    <div data-role="content">
        <p>Show coins here</p>

    </div><!-- /content -->

    </div><!-- /page -->


</body>

1 个答案:

答案 0 :(得分:0)

你必须参考所有这些:

<link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.css" />
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.js"></script>

在包含

的页面中
<a href="use_coins.html" data-rel="dialog">Open dialog Box</a>