                var map = null;
                var geocoder = null;

                function initialize() {

                  if (GBrowserIsCompatible()) {
                    geocoder = new GClientGeocoder();
                    
                    function showAddress(address) {
                      if (geocoder) {

                        geocoder.getLatLng(
                          address,
                          function(point) {
                            if (!point) {
                              /* document.getElementById("map").style.display="none"; */
                                map = new GMap2(document.getElementById("map"));
                                map.setCenter(new GLatLng(49.263889, -123.14), 10);
                                map.addControl(new GSmallMapControl());
                                map.setCenter(point, 10);
// Create our "tiny" marker icon
var tinyIcon = new GIcon();
tinyIcon.image = "http://labs.google.com/ridefinder/images/mm_20_red.png";
tinyIcon.shadow = "http://labs.google.com/ridefinder/images/mm_20_shadow.png";
tinyIcon.iconSize = new GSize(12, 20);
tinyIcon.shadowSize = new GSize(22, 20);
tinyIcon.iconAnchor = new GPoint(6, 20);
tinyIcon.infoWindowAnchor = new GPoint(5, 1);

// Set up our GMarkerOptions object literal
  markerOptions = {icon:tinyIcon};
  var point = new GLatLng(49.263889, -123.14);
// use the following line to just display the maker
  /* map.addOverlay(new GMarker(point, markerOptions)); */
         
         var marker = (new GMarker(point, markerOptions));
         GEvent.addListener(marker, "mouseover", function() {
           var html = '<div style="width: 180px; padding-right: 10px">Address not available.<\/div>';
           marker.openInfoWindowHtml(html, false);
         });
         map.addOverlay(marker);
         GEvent.trigger(marker, "click");

                            } else {
                                map = new GMap2(document.getElementById("map"));
                                map.setCenter(new GLatLng(37.4419, -123.06), 13);
                                map.addControl(new GSmallMapControl());
                            
                              map.setCenter(point, 13);
                            
                              var marker = new GMarker(point);
 


                                var infoTabs = [
                                  new GInfoWindowTab('Location','<b>Location Address</b><br>100 Esplanade Avenue <br>Vancouver, British Columbia, V0M 1K0<br />'),                                                        
                                  new GInfoWindowTab('Directions', 'Enter your address:<br><form action="http://maps.google.com/maps" method="get" target="_blank"><input type="text" size="30" maxlength="60" name="saddr" id="saddr" value=""><br><input class="button" value="Get Directions" type="submit"><input type="hidden" name="daddr" value="100 Esplanade Avenue , Vancouver, British Columbia V0M 1K0"></form>')]; 
                                                             
                                                                      
                              GEvent.addListener(marker, 'click', function() {marker.openInfoWindowTabsHtml(infoTabs);});

                              map.addOverlay(marker);
                            /*  marker.openInfoWindowTabsHtml(infoTabs); */
                            }
                          }
                        );
                      }
                    }
        
        showAddress('100 Esplanade Avenue , Vancouver, British Columbia');
        }
                } 