
	
	// Creates a marker at the given point with the given number label
	function createMarker(point, number) {
	  var marker = new GMarker(point);
	  GEvent.addListener(marker, "click", function() {
	    marker.openInfoWindowHtml("Genesis Blinds<br>Block 1, Unit 4,<br>Tollcross Industrial Estate<br>Causewayside Street<br>GLASGOW<br>G32 8LP");
	  });
	  return marker;
	}

	
    function load_map( given_lat, given_long, given_zoom, given_controls ) {
			
		if (GBrowserIsCompatible()) {
		
			
			if ( given_lat == "" || given_lat == 0)
				given_lat = 55.839267;
			
			if (given_long == "" || given_long == 0 )
				given_long = -4.171937;
			
			if (given_zoom == "" || given_zoom == 0 )
				given_zoom = 15;
				
			if (given_controls == "" || given_controls == 0 )
				given_controls = s;				
		
	        var map = new GMap2(document.getElementById("map"),G_NORMAL_MAP);
			var default_lat = 55.839267;
			var default_long = -4.171937;
			var default_zoom = 15;
			
				map.addControl(new GMapTypeControl());
			
				if ( given_controls == "L" || given_controls == "l" )
					map.addControl(new GLargeMapControl());
				else
					map.addControl(new GSmallMapControl());
					
				map.setCenter(new GLatLng(given_lat, given_long), given_zoom, G_NORMAL_MAP );
				
				// Create the Genesis Logo
				var icon = new GIcon();
				icon.image = "http://preview.genesisblinds.co.uk/images/genesis_marker.gif";
				icon.iconSize = new GSize(176, 116);
				icon.iconAnchor = new GPoint(176, 116);
				icon.infoWindowAnchor = new GPoint(176, 1);				
				
				// var point = new GLatLng(55.842473,-4.179600);
				var point = new GLatLng(55.841190, -4.171937);
				map.addOverlay(new GMarker(point, icon));
  
 				var icon = new GIcon();
				icon.image = "http://preview.genesisblinds.co.uk/images/mm_20_red.png";
				icon.shadow = "http://preview.genesisblinds.co.uk/images/mm_20_shadow.png";
				icon.iconSize = new GSize(12, 20);
				icon.shadowSize = new GSize(22, 20);
				icon.iconAnchor = new GPoint(6, 20);
				icon.infoWindowAnchor = new GPoint(5, 1);

				var point = new GLatLng(55.841190, -4.171937);
				map.addOverlay(new GMarker(point, icon));
				
		}
	
	}


