var membermap = {

	  map 		  : null 
    , initialise : function(e){
      	if(GBrowserIsCompatible()) {
			var canvas = document.getElementById("map_canvas");
			if(canvas) {
	            membermap.map = new GMap2(canvas);
	            membermap.map.setCenter(new GLatLng(53.747579, -2.433249), 10);
	            membermap.map.setUIToDefault();
			}
        }
    }
}



$(function(e){
   	membermap.initialise();
	$('#g-bubble').hide();
		$('#g-bubble > li').each(
           function (e) {
               var lat        = $(this).children('.geo').children('.latitude').html();
               var lon        = $(this).children('.geo').children('.longitude').html();
               var latLon 	   = new GLatLng(lat,lon);
               var memberLoc  = new GMarker(latLon);
               $(this).children('.geo').remove();
               memberLoc.bindInfoWindowHtml($(this).html());
               membermap.map.addOverlay(memberLoc);
               membermap.map.panTo(latLon)
    	}
	);
});
