    function pToolsMarker()
    {
        this.GeoLatitude
        this.GeoLongitude
        this.Title
        this.Html
    }
    
    var pToolsMapMarkers = new Array();
    
    function initializeMap()
    {
        if (document.getElementById("map"))
        {
            if (pToolsMapMarkers.length > 0)
            {
                document.getElementById("map").style.display='block';
                initializeGoogleMap()
            }
            else
            {
                document.getElementById("map").style.display='none';
            }
        }
    }    

    function initializeGoogleMap()
    {
        if (GBrowserIsCompatible()) 
        { 


      // Display the map, with some controls and set the initial location 
      var map = new GMap2(document.getElementById("map"));
      map.addControl(new GSmallMapControl());
      map.addControl(new GMapTypeControl());
      map.addControl(new GOverviewMapControl(new GSize(100,100)));
      map.setCenter(new GLatLng(53.34594, -6.2663269),12);
    
       var markers = new Array();
      
      // Set up the markers
      for(var i=0;i<pToolsMapMarkers.length;i++)
	  {
          var pToolsMarker = pToolsMapMarkers[i];
          var html = '<div class="googleMapInfoWindow">' + pToolsMarker.Html + '</div>';
          var point = new GLatLng(pToolsMarker.GeoLatitude,pToolsMarker.GeoLongitude);
          var marker = createMarker(point,html, pToolsMarker.Title)
          
          map.addOverlay(marker);
          markers[markers.length] = marker
	  }

      var bounds = new GLatLngBounds;
      for (var i=0; i<markers.length; i++) 
      {
         bounds.extend(markers[i].getPoint());
      }

      if (markers.length > 1)
      {
        map.setZoom(map.getBoundsZoomLevel(bounds));
      }

      map.setCenter(bounds.getCenter());


         }
    
    // display a warning if the browser was not compatible
    else {
      alert("Sorry, the Google Maps API is not compatible with this browser");
    }
    }
    
      // A function to create the marker and set up the event window
      // Dont try to unroll this function. It has to be here for the function closure
      // Each instance of the function preserves the contends of a different instance
      // of the "marker" and "html" variables which will be needed later when the event triggers.    
      function createMarker(point,html, title) {
        var opts = new Object(); 
        opts.title = title; 

        
        var marker = new GMarker(point, opts);
        GEvent.addListener(marker, "click", function() {
          marker.openInfoWindowHtml(html);
        });
        return marker;
      }


   