/* a small but powerful routine to avoid spam emails */
function mail(email, action)
{
  while (email.search(/\|/) != -1)
  {
    email = email.replace(/\|/,"");
  }

  if (action == 0) window.location = "mailto:" + email;
  if (action == 1) document.write(email);
}



function create_google_map(){

	document.write('<sc'+'ript src="http://maps.google.com/maps?file=api&v=2&key=ABQIAAAAe9fPlVBsJOYaWi9hYN9RkhTqqocloXu82HWetC3Fe4K4qWHinBSvB_k7pc_1dKE5pH6s2TRCya45TQ" type="text/javascript"></scr'+'ipt>');
	function mapload() {
		 if (GBrowserIsCompatible()) {
			var gmap = new GMap2(document.getElementById("map"), {mapTypes:[G_HYBRID_MAP, G_SATELLITE_MAP, G_NORMAL_MAP]});
			gmap.addControl(new GSmallMapControl());
			gmap.addControl(new GMapTypeControl());
			gmap.addControl(new GOverviewMapControl());
			gmap.setCenter(new GLatLng(53.600149,10.091883),14);
			gmap.addOverlay(createMarker( new GLatLng(53.600149,10.091883), "Gymnasium Osterbek<br />Turnierstieg 24<br />22179 Hamburg"));
		 }
	}
	function createMarker(point, mtext) {
		var marker = new GMarker(point);
		GEvent.addListener(marker, "click", function() {
			marker.openInfoWindowHtml( mtext );
		});
		return marker;
	}
	window.setTimeout(mapload,500);

}
