Google Map for My Blog

來源:互聯網
上載者:User

 Google Map for My Blog

Author: ZhangGuiQuan

KeyWords: Google Map and Wibsite

Google Maps is a  very cool webgis Application,basing on some traditional web and maps technologies and the popular web tchnology Ajax, whitch is considered as the core technoloy of the web 2.0. It's a useful tools for the native people and a gift for the human beings. Through the google maps application you can search locations as you want and as a GIS tool to navigate your driving and any other thing. Google Maps API have being a part of the Google Open Source Program and it available on website : http://www.google.com/apis/maps/ new.  Though Google Maps is a  very complex application,you can create simple applications by the standard API and some JavaScript technologies. Start now, to create you own map.

The Google Maps API lets you embed Google Maps in your own web pages with JavaScript. You can add overlays to the map (including markers and polylines) and display shadowed "info windows" just like Google Maps.

If you want to Put Google Maps on Your Own Web Site Sign up for a Google Maps API key  here.The Maps API is a free beta service, available for any web site that is free to consumers. Please see the terms of use for more information.To use the Maps API on an intranet or in a non-publicly accessible application, please check out Google Maps for Enterprise.

The following is a example of the process to useing the google map, just as a demo for my blog.

Your key is:

ABQIAAAAHNY_AU0cvcSGXupctRLBdhRgv5BhoHLEsxzNIZ_***
(The starts are omited for some reason)

This key is good for all URLs in this directory:

http://blog.csdn.net/natureboy520/

Here is an example web page to get you started on your way to mapping glory:

 

<!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">
  <head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <title>Google Maps JavaScript API Example</title>
    <script src="http://maps.google.com/maps?file=api&amp;v=2&amp;            key=ABQIAAAAHNY_AU0cvcSGXupctRLBdhRgv5BhoHLEsxzNIZ_***           CSgRTCceBGl4YYpLxlYffPx_WObcQTyw"
      type="text/javascript"></script>
    <script type="text/javascript">...
    //<![CDATA[
    function load() ...{
      if (GBrowserIsCompatible()) ...{
        var map = new GMap2(document.getElementById("map"));
        map.setCenter(new GLatLng(37.4419, -122.1419), 13);
      }
    }
    //]]>
    </script>
  </head>
  <body onload="load()" onunload="GUnload()">
    <div id="map" style="width: 500px; height: 300px"></div>
  </body>
</html>

 

 A Graphic from the demo application as follows:

 

 

 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.