Gmap jquery android



我正在使用Phonegap+JQueryMobile+JQuery在我的index.html中创建一个地图。有一个问题,在浏览器中我的代码运行良好,但当我尝试在手机上运行时,却没有显示地图。

这是代码:

<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet"
    href="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.css" />
<script
    src="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.js"></script>
<script src="datepicker.js"></script>
<script type="text/javascript"
    src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>
<script type="text/javascript"
    src="http://maps.google.com/maps/api/js?sensor=false"></script>
<script type="text/javascript"
    src="http://jquery-ui-map.googlecode.com/svn/trunk/ui/min/jquery.ui.map.full.min.js"></script>
<script type="text/javascript">
    $(function() {
        $("#map").gmap();
    });
</script>
</head> <body><div id="map" style="height: 350px; width: 600px"></div></body></html>

我认为错误是在脚本源上,因为我需要为手机导入正确的gmap,但我不知道。

谢谢!

您在AndroidManifest.xml中启用了互联网访问吗?

<uses-permission android:name="android.permission.INTERNET" />

最新更新