<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<style type="text/css">
body, html,#allmap { 100%;height: 100%;overflow: hidden;margin:0;font-family:"微软雅黑";}
</style>
<script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=4d06aa5b2c816cc52a1a9cd008808c68"></script>
<title>地图展示</title>
</head>
<body>
<div id="allmap"></div>
</body>
</html>
<script src="./lib/base/base.js"></script>
<script type="text/javascript">
var lon=getQueryString('lon') //目标位置
var lat=getQueryString('lat')
var mylon=getQueryString('mylon')//自己的位置
var mylat=getQueryString('mylat')
// 百度地图API功能
//添加地图类型控件
var map = new BMap.Map("allmap");
var point = new BMap.Point(lon,lat);
map.centerAndZoom(point, 20); //控制精度
var pt = new BMap.Point(lon,lat);
// var myIcon = new BMap.Icon("./img/bitbug_favicon.ico", new BMap.Size(30,27));
var marker2 = new BMap.Marker(pt); // 创建标注
map.addOverlay(marker2);
//设置的导航步行线路
// var walking = new BMap.WalkingRoute(map, {
// renderOptions: {
// map: map,
// autoViewport: true
// }
// });
// var start = new BMap.Point(mylon,mylat);
// var end = new BMap.Point(lon, lat);
// walking.search(start, end);
</script>