<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no" />
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title>搜狗地图 JavaScript API 示例: 加载指定城市区域的地图</title>
<style type="text/css">
html {height: auto;}
body {height: auto;margin: 0;padding: 0;}
#map_canvas {width:1000px;height: 500px;position: absolute;}
@media print {#map_canvas {height: 950px;}}
</style>
<script type="text/javascript" src="http://api.go2map.com/maps/js/api_v2.5.1.js"></script>
<script type="text/javascript">
 /**
  * 加载指定城市区域的地图
  */
  function initialize() {
    var myOptions = {
      zoom: 10,
      center: new sogou.maps.Point(12956000,4824875) //目标地点的坐标
    }
    var map = new sogou.maps.Map(document.getElementById("map_canvas"),
                                  myOptions);
  }
</script>
</head>
<body onload="initialize()">
  <div ></div>
</body>
</html>

  

 

相关文章:

  • 2022-12-23
  • 2021-11-29
  • 2021-06-01
  • 2022-12-23
  • 2021-06-13
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-02-12
  • 2022-12-23
  • 2022-01-29
  • 2022-12-23
  • 2022-01-23
  • 2021-12-15
相关资源
相似解决方案