Google map API V3 offline Edition

Source: Internet
Author: User

In the offline version of GoogleMap API V3, you can still use the Google map service without calling GoogleMap javascrui online.

Google map's last license application in China has passed, and there are still no official instructions. It is very likely that Google map will be suspended in May July, this is a great sorrow for those of us who often use Google maps or secondary developers!

This may be a good thing for map service providers in China. More cakes can be divided. However, for our users, especially map applications developed using the free GoogleMap API in many enterprises and websites, it is a challenge and can only be replaced with other map servers, regardless of whether the service is charged or not, you need to re-develop the service if you switch from the platform. Is there a way for us to continue using it after Google leaves us? I think of the offline version of the previously created Google map API. With this, we can place it on our own server, instead of calling these scripts from the Google map server. Of course, I still want you to use the official version for commercial purposes. Pay attention to copyright issues.

Some time ago, I made a Google Map API V3 offline version. After testing, the basic functions should be satisfied. You can download and try it.

Yes: googlemapapiv3.zip

After using the offline version, you only need to load the mapapi. js file, for example:

<! 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; charsets = UTF-8" />
< Link Href = "Http://code.google.com/apis/maps/documentation/javascript/examples/default.css" REL = "Stylesheet" Type = "Text/CSS" />
< Title > Google Maps javascript API V3 example: Map simple </ Title >
< Script Type = "Text/JavaScript" SRC = "Mapapi. js" > </ Script >
< Script Type = "Text/JavaScript" >
Function Initialize (){
VaR Mylatlng = New Google. Maps. latlng ( - 34.397 , 150.644 );
VaR Myoptions = {
Zoom: 8 ,
Center: mylatlng,
Maptypeid: Google. Maps. maptypeid. Roadmap
}
VaR Map = New Google. Maps. Map (document. getelementbyid ( " Map_canvas " ), Myoptions );
}
</ Script >
</ Head >
< Body Onload = "Initialize ()" >
< Div ID = "Map_canvas" > </ Div >
</ Body >

</Html>

If you are interested, you can test it. If you find any problems, we can try to solve them together.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.