当前位置: 代码迷 >> Java Web开发 >> JSP怎么做出google地图效果
  详细解决方案

JSP怎么做出google地图效果

热度:97   发布时间:2016-04-17 11:09:12.0
JSP如何做出google地图效果
如题。可以留下资料或相关信息,一旦确认可行立即给分。

------解决方案--------------------
google map有他自己的api 调起js就可以运行,给你个例子
JScript code
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml">  <head>    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>    <title>Google 地图 JavaScript API 示例: 简单的地图</title>    <script src="http://ditu.google.cn/maps?file=api&amp;v=2&amp;key=ABQIAAAAzr2EBOXUKnm_jVnk0OJI7xSosDVG8KKPE1-m51RBrvYughuyMxQ-i1QfUnH94QxWIa6N4U6MouMmBA&hl=zh-CN"            type="text/javascript"></script>    <script type="text/javascript">    function initialize() {      if (GBrowserIsCompatible()) {        var map = new GMap2(document.getElementById("map_canvas"));       //维度,经度        map.setCenter(new GLatLng(39.917, 116.397), 1);      }    }    </script>  </head>  <body onload="initialize()" onunload="GUnload()">    <div id="map_canvas" style="width: 500px; height: 300px"></div>  </body></html>
------解决方案--------------------
Google Map API
http://code.google.com/intl/zh-CN/apis/maps/documentation/reference.html
  相关解决方案