function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}

function preloadImages() { //v3.0
	var d = document;
		if(d.images) {
			if(!d.MM_p)
				d.MM_p=new Array();
    
		var i,j = d.MM_p.length
		var a = MM_preloadImages.arguments;
	
		for(i = 0; i < a.length; i++)
			if(a[i].indexOf("#") != 0) {
				d.MM_p[j] = new Image;
				d.MM_p[j++].src = a[i];
				alert(a[i]);
			}
		}
}

function GB_hide()
{
	GB_IFRAME.src = "";
	hideElement(GB_WINDOW);
	hideElement(GB_HEADER);
	hideElement(GB_OVERLAY);
	location.reload();
}

function exWnd(theURL,winName,features)
{
	window.open(theURL,winName,features);
}

function loadMap() {
  if (GBrowserIsCompatible()) {
	// define the crosshair tile layer and its required functions
	var crossLayer = new GTileLayer(new GCopyrightCollection(""), 0, 15);
	crossLayer.getTileUrl =  function(tile, zoom) {
	  return "./include/tile_crosshairs.png";
	}
	crossLayer.isPng = function() {return true;}

	// Create a new map type incorporating the tile layer
	var layerTerCross = [ G_PHYSICAL_MAP.getTileLayers()[0],
						  crossLayer ];
	var mtTerCross = new GMapType(layerTerCross,
								  G_PHYSICAL_MAP.getProjection(), "Ter+");

	var map = new GMap2(document.getElementById("map_canvas"),
		{ size: new GSize(493,358) } );
	map.addMapType(G_PHYSICAL_MAP);
	map.addMapType(mtTerCross);
	map.setCenter(new GLatLng(52.49869382443106,13.345448970794678), 15);
	map.addControl(new GLargeMapControl())

	var mapControl = new GHierarchicalMapTypeControl();
	
	// Set up map type menu relationships
	mapControl.clearRelationships();
	mapControl.addRelationship(G_SATELLITE_MAP, G_HYBRID_MAP, "Labels", false);
	mapControl.addRelationship(G_PHYSICAL_MAP, mtTerCross, "Crosshairs");

	// Add control after you've specified the relationships
	map.addControl(mapControl);
	
	map.addOverlay(new GMarker(map.getCenter()));
  }
}