//鍒涘缓鍜屽垵濮嬪寲鍦板浘鍑芥暟锛
function initMap(){
createMap();//鍒涘缓鍦板浘
setMapEvent();//璁剧疆鍦板浘浜嬩欢
addMapControl();//鍚戝湴鍥炬坊鍔犳帶浠
addMarker();//鍚戝湴鍥句腑娣诲姞marker
}
//鍒涘缓鍦板浘鍑芥暟锛
function createMap(){
var map = new BMap.Map("dituContent");//鍦ㄧ櫨搴﹀湴鍥惧鍣ㄤ腑鍒涘缓涓€涓湴鍥
var point = new BMap.Point(113.920585,22.544936);//瀹氫箟涓€涓腑蹇冪偣鍧愭爣
map.centerAndZoom(point,16);//璁惧畾鍦板浘鐨勪腑蹇冪偣鍜屽潗鏍囧苟灏嗗湴鍥炬樉绀哄湪鍦板浘瀹瑰櫒涓
window.map = map;//灏唌ap鍙橀噺瀛樺偍鍦ㄥ叏灞€
}
//鍦板浘浜嬩欢璁剧疆鍑芥暟锛
function setMapEvent(){
map.enableDragging();//鍚敤鍦板浘鎷栨嫿浜嬩欢锛岄粯璁ゅ惎鐢?鍙笉鍐?
map.enableScrollWheelZoom();//鍚敤鍦板浘婊氳疆鏀惧ぇ缂╁皬
map.enableDoubleClickZoom();//鍚敤榧犳爣鍙屽嚮鏀惧ぇ锛岄粯璁ゅ惎鐢?鍙笉鍐?
map.enableKeyboard();//鍚敤閿洏涓婁笅宸﹀彸閿Щ鍔ㄥ湴鍥
}
//鍦板浘鎺т欢娣诲姞鍑芥暟锛
function addMapControl(){
//鍚戝湴鍥句腑娣诲姞缂╂斁鎺т欢
var ctrl_nav = new BMap.NavigationControl({anchor:BMAP_ANCHOR_TOP_LEFT,type:BMAP_NAVIGATION_CONTROL_LARGE});
map.addControl(ctrl_nav);
//鍚戝湴鍥句腑娣诲姞缂╃暐鍥炬帶浠
var ctrl_ove = new BMap.OverviewMapControl({anchor:BMAP_ANCHOR_BOTTOM_RIGHT,isOpen:1});
map.addControl(ctrl_ove);
//鍚戝湴鍥句腑娣诲姞姣斾緥灏烘帶浠
var ctrl_sca = new BMap.ScaleControl({anchor:BMAP_ANCHOR_BOTTOM_LEFT});
map.addControl(ctrl_sca);
}
//鏍囨敞鐐规暟缁
var markerArr = [{title:"娣卞湷鏄撲俊绉戞妧鑲′唤鏈夐檺鍏徃",content:"鍦板潃锛氭繁鍦冲競鍗楀北鍖烘澗鐧借矾1002鍙风櫨鏃轰俊楂樼鎶€宸ヤ笟鍥?鍖?鏍?妤硷紝缃戝潃锛歸ww.esinidc.com锛岃仈绯荤數璇濓細400-6856-167 0755-66822671 82135100",point:"113.920603|22.546738",isOpen:0,icon:{w:23,h:25,l:23,t:21,x:9,lb:12}}
];
//鍒涘缓marker
function addMarker(){
for(var i=0;i