
    //<![CDATA[

		var iconHouse = new GIcon(); 
		iconHouse.image = '/site/images/map_icons_off.png';
		iconHouse.iconSize = new GSize(24, 24);
		iconHouse.iconAnchor = new GPoint(6, 18);
		iconHouse.infoWindowAnchor = new GPoint(12, 6);

    if (GBrowserIsCompatible()) {
      var gmarkers = [];
      var htmls = [];
      var i = 0;
    
	
			var mP = {
			
			
				init: function() {
					if(!document.getElementById('singlemap')) {
						return;
					}
					
					var lat = latlng[0];
					var lng = latlng[1];
					var newhtml = latlng[2];
					
				
		      // create the map
		      mP.map = new GMap2(document.getElementById("singlemap"));
		      mP.map.addControl(new GSmallMapControl());
		      mP.map.addControl(new GMapTypeControl());
		      mP.map.setCenter(new GLatLng(lat,lng), 15);
		
		
		
		      // obtain the attribues of each marker
	        var point = new GLatLng(lat,lng);
	        var html = newhtml;
	        var label = "Marker One";
	        // create the marker
	        var marker = mP.createMarker(point,label,html);
	        mP.map.addOverlay(marker);
				
		     
				
				
				},
			
			

					// A function to create the marker and set up the event window
	      createMarker: function(point,name,html) {
	        var marker = new GMarker(point, iconHouse);
	
	        GEvent.addListener(marker, "click", function() {
	          marker.openInfoWindowHtml(html);
	        });
	
	        gmarkers[i] = marker;
	        htmls[i] = html;
	
	        i++;
	        return marker;
	      },
	
	
	      // This function picks up the click and opens the corresponding info window
	      myclick: function(i) {
	        gmarkers[i].openInfoWindowHtml(htmls[i]);
	      }



			
      
	      
	    }
    
    
			window.addEvent('domready', mP.init);
			window.addEvent('unload', GUnload);
    
    } else {
      alert("Sorry, the Google Maps API is not compatible with this browser");
    }

    //]]>