<!--#include file="../lib/base.asp"-->
<%
dim point,lng,lat,zoom
lng="120.939545"
lat="31.388211"
zoom="12"
point=eycms.getsys(eycms.fget("p",0))
if eycms.strlen(point)>0 and ubound(split(point,","))=2 then
	lng=split(point,",")(0)
	lat=split(point,",")(1)
	zoom=split(point,",")(2)
end if

dim mInfo
mInfo=eycms.getsys("webname")
if eycms.strlen(eycms.getsys("my_add"))>0 then mInfo=mInfo & "<br>地址：" & eycms.getsys("my_add")
if eycms.strlen(eycms.getsys("my_tel"))>0 then mInfo=mInfo & "<br>电话：" & eycms.getsys("my_tel")
%>
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<title>百度地图</title>
<style>
body,html{width:100%;height:100%;margin:0;font-family:"微软雅黑";font-size:14px;}
*{margin:0;padding:0;}
#eycms-map{min-height:400px;width:100%;}
p{margin:0;padding:5px 0;}
</style>
<script src="http://api.map.baidu.com/api?v=2.0&ak=D2d3b9d5a30342fb3610bcf2c5dd8178"></script>
</head>
<body>
<div id="eycms-map">地图加载中...</div>
<script>
var map=new BMap.Map("eycms-map");
var point=new BMap.Point(<%=lng%>,<%=lat%>);
var marker=new BMap.Marker(point);
var infoWindow=new BMap.InfoWindow("<p><strong><%=mInfo%></strong></p>");
map.centerAndZoom(point,<%=zoom%>);
map.enableScrollWheelZoom(true);
map.addOverlay(marker);
marker.openInfoWindow(infoWindow,point);
marker.setAnimation(BMAP_ANIMATION_BOUNCE);
marker.addEventListener("click",function(){this.openInfoWindow(infoWindow);});
</script>
</body>
</html>