Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Google Map from Scratch

Go to End



Community Member, 1 Post

28 October 2008 at 12:48am

I would like to have a Google map which only can point out a part of the globe not the whole, for no reason. I have followed some the instructions of Developer but i am not able to succeed. More over i want to run this site on a Virtual Machine so i want the Google App to be created as http://localhost/silverstripe/

and I got the char sequence as a API key

The Example webpage is this

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
<html xmlns="">
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title>Google Maps JavaScript API Example</title>
<script src=";v=2&amp;key=ABQIAAAAR961RmwqX6JM72dPhgxpXRSl2cCGfYLKpuS8wz_6fO3TDVgOThQQiyDYY7D2EVZCJe7_dnaqrSGN_Q"
<script type="text/javascript">


function load() {
if (GBrowserIsCompatible()) {
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(37.4419, -122.1419), 13);

<body onload="load()" onunload="GUnload()">
<div id="map" style="width: 500px; height: 300px"></div>

Thanks in Advance for your help to me