add
This commit is contained in:
56
Assets/trCRM/upgradeRes4Publish/priority/www/baidumap.html
Normal file
56
Assets/trCRM/upgradeRes4Publish/priority/www/baidumap.html
Normal file
@@ -0,0 +1,56 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>Hello, World</title>
|
||||
<style type="text/css">
|
||||
html {
|
||||
height: 100%
|
||||
}
|
||||
|
||||
body {
|
||||
height: 100%;
|
||||
margin: 0px;
|
||||
padding: 0px
|
||||
}
|
||||
|
||||
#container {
|
||||
height: 100%
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript" src="http://api.map.baidu.com/api?v=3.0&ak=T59gK6PmC3lV4gS8Mep3daOuzBlz5X4v">
|
||||
//v3.0版本的引用方式:src="http://api.map.baidu.com/api?v=3.0&ak=您的密钥"
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="container"></div>
|
||||
<script type="text/javascript">
|
||||
function getQueryVariable(variable) {
|
||||
var query = window.location.search.substring(1);
|
||||
var vars = query.split("&");
|
||||
for (var i = 0; i < vars.length; i++) {
|
||||
var pair = vars[i].split("=");
|
||||
if (pair[0] == variable) {
|
||||
return pair[1];
|
||||
}
|
||||
}
|
||||
return (false);
|
||||
}
|
||||
|
||||
var map = new BMap.Map("container");
|
||||
// 创建地图实例
|
||||
|
||||
var latitude = getQueryVariable("latitude")
|
||||
var longitude = getQueryVariable("longitude")
|
||||
latitude = latitude == null ? 116.404 : parseFloat(latitude)
|
||||
longitude = longitude == null ? 39.915 : parseFloat(longitude)
|
||||
var point = new BMap.Point(longitude, latitude);
|
||||
map.centerAndZoom(new BMap.Point(longitude, latitude), 18); // 初始化地图,设置中心点坐标和地图级别
|
||||
map.addControl(new BMap.GeolocationControl());
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7401b6f74f67144d4a8b90c2208b666e
|
||||
TextScriptImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user