<script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=你的AK"></script>
<div id="container" style=" 100%;height:540px"></div>
<script> CreateMap("121.48789949", "31.24916171"); //创建地图 lat经度 lng纬度 function CreateMap(lat, lng) { // 百度地图 var map = new BMap.Map('container'); // 创建地图实例 var point = new BMap.Point(lat, lng); // 创建点坐标 map.centerAndZoom(point, 21); // 初始化地图, 设置中心点坐标和地图级别 var marker = new BMap.Marker(point); map.addOverlay(marker); } </script>