  
	var WStarGoogleMaps =
	{
		Canvas : null,
		Map : null,
		GeoCoder : null,
    	init : function () 
		{
      		if (GBrowserIsCompatible()) 
			{
				var GoogleMapsContainer = WStarCore.getElementsByClass("googlemaps");
				
				if ( GoogleMapsContainer.length > 0 )
				{
					for ( var i = 0 ; i < GoogleMapsContainer.length; i++)
					{
						var MapAddress = GoogleMapsContainer[i].rel;
						//WStarCore.DebugMessages(' MapAddress=' + MapAddress);
						//var google_map_canvas = document.createElement("div");
						//google_map_canvas.id="google_map_canvas"+i;
						//google_map_canvas.style.width= '437px'; 
						//google_map_canvas.style.height = '300px';
						
						//var google_map_notfound = document.createElement("div");
						//google_map_notfound.id="google_map_notfound"+i;
						//google_map_notfound.style.display= 'none'; 
						
						//GoogleMapsContainer[i].appendChild(google_map_canvas);
						//GoogleMapsContainer[i].appendChild(google_map_notfound);
						 GoogleMapsContainer[i].id = "google_map_canvas"+i;
						
						WStarGoogleMaps.Canvas = GoogleMapsContainer[i];
						
	
						//WStarGoogleMaps.Canvas = document.getElementById("google_map_canvas"+i);
						
						
						if ( WStarGoogleMaps.Canvas )
						{
			        		WStarGoogleMaps.Map = new GMap2(WStarGoogleMaps.Canvas);
			       			//WStarGoogleMaps.Map.setCenter(new GLatLng(37.4419, -122.1419), 13);
			
							var mapTypeControl = new GMapTypeControl();
							var topRight = new GControlPosition(G_ANCHOR_TOP_RIGHT, new GSize(10,10));
			        		var bottomRight = new GControlPosition(G_ANCHOR_BOTTOM_RIGHT, new GSize(10,10));
			        		WStarGoogleMaps.Map.addControl(mapTypeControl, topRight);
							GEvent.addListener(WStarGoogleMaps.Map, "dblclick", function() 
							{
								WStarGoogleMaps.Map.removeControl(mapTypeControl);
								WStarGoogleMaps.Map.addControl(new GMapTypeControl(), bottomRight);
							});
							WStarGoogleMaps.Map.addControl(new GSmallMapControl());
			
							WStarGoogleMaps.GeoCoder = new GClientGeocoder();
			
							//WStarGoogleMaps.showAddress("5 Down St, Esk"); // My Address
							//WStarGoogleMaps.showAddress("72 Formation St, WACOL, QLD, Australia, 4076"); // Western Star Trucks, Where I work.
							WStarGoogleMaps.showAddress(MapAddress); // Western Star Trucks, Where I work.
						}
					}
	      		}
			}
    	},
        showAddress : function (address) 
		{
      		if (WStarGoogleMaps.GeoCoder) 
			{
        		WStarGoogleMaps.GeoCoder.getLatLng(
          			address,
          			function(point) 
					{
            			if (!point) 
						{
							WStarGoogleMaps.Map = null;
							WStarGoogleMaps.Canvas.innerHTML = 'No Google Map found for address [ ' + address + ' ] ';
            			} 
						else 
						{
              				WStarGoogleMaps.Map.setCenter(point, 13);
              				var marker = new GMarker(point);
              				WStarGoogleMaps.Map.addOverlay(marker);
              				marker.openInfoWindowHtml(address);
            			}
						
          			}
        		);
      		}
    	}
	}
	//window.onload=WStarGoogleMaps.init;
	WStarCore.start(WStarGoogleMaps);

	//document.write('<div id="google_map_canvas" style="width: 500px; height: 300px"></div>');
	//document.write('<div id="google_map_notfound" style="display:none"></div>');



