
    function load() {
      if (GBrowserIsCompatible()) {
        var map = new GMap2(document.getElementById("map"));
        map.setCenter(new GLatLng(43.53172, -5.658578), 13);
          
          map.addControl(new GLargeMapControl());
          
        //marker with ext info window with a red skin
          var redIcon1 = new GIcon(G_DEFAULT_ICON);
          redIcon1.iconAnchor = new GPoint(0, 0);
          redIcon1.infoWindowAnchor = new GPoint(7, 0 ); 
          marker = new GMarker( new GLatLng(32, -100), redIcon1);
          GEvent.addListener(marker, 'click', 
            function(){ 
              marker.openExtInfoWindow(
                map,
                "custom_info_window_red",
                "<p>cargando pesta&ntilde;as...</p>",
                {beakOffset: 3, ajaxUrl: 'ajax/ajaxTabs.html'}
              ); 
            }
          );
          GEvent.addDomListener(map, 'extinfowindowupdate',function(){
            var windowContent = document.getElementById("custom_info_window_red_contents");
            var tabs = new Array(document.getElementById("tab0"),document.getElementById("tab1"));
            if( tabs.length > 0 ){
              var tabContentsArray = new Array(tabs.length);
              for( i=0; i < tabs.length; i++){
                tabContentsArray[i] = document.getElementById("tab"+i+"_content");
                if( i > 0){
                  hide(tabContentsArray[i]);
                }
                tabs[i].setAttribute("name", i.toString());
              
                GEvent.addDomListener(tabs[i],"click",function(){
                  var tabIndex = this.getAttribute("name");
                
                  for(tabContentIndex=0; tabContentIndex < tabs.length; tabContentIndex++){
                    if( tabContentIndex == tabIndex ){
                      show(tabContentsArray[tabContentIndex]);
                    }else{
                      hide(tabContentsArray[tabContentIndex]);
                    }
                  }
                  map.getExtInfoWindow().resize();
                });
              }
            }
          });
          map.addOverlay(marker);
        }
      }
      /**
       * Helper function to hide the given DOM element
       * @param {Object} element The DOM element that should be hidden
       */
      function hide(element){
        element.style.display = "none";
        element.style.position = "absolute";
      }
      /**
       * Helper function to show the given DOM element
       * @param {Object} element The DOM element that should be displayed
       */
      function show(element){
        element.style.display = "block";
        element.style.position = "relative";
      }
          

