// JavaScript Document

//Page Forwarding Function (to make IE happy)


function hide_display(id) {
	if (document.getElementById(id).style.display == "block") {
		document.getElementById(id).style.display = "none";
	} else {
		document.getElementById(id).style.display = "block";
	}
}

   var map = null;
    	var geocoder = null;
      	       
       
    function initialize() {
    	  
      if (GBrowserIsCompatible()) {
        map = new GMap2(document.getElementById("map"));
       // map.setCenter(new GLatLng(37.4419, -122.1419), 13);
        
        map.addControl(new GSmallMapControl());
        map.addControl(new GMapTypeControl());
       //map.addControl(new google.maps.LocalSearch(), new GControlPosition(G_ANCHOR_BOTTOM_RIGHT, new GSize(10,18)));
     
        
        
        geocoder = new GClientGeocoder();
      }
    }

    function showAddress(name,address1,address) {
  	//alert(address1+" "+address);
      if (geocoder) {
        geocoder.getLatLng(
          address1+" "+address,
          function(point) {
            if (!point) {
              //alert(address + " not found");
            } else {
              map.setCenter(point, 13);
              var marker = new GMarker(point);
              var myHtml = "<b>" + name + "</b><br>#" + address1 + "<br>";
              map.addOverlay(marker);
              //marker.openInfoWindowHtml(myHtml + address);
              /*marker.openInfoWindowHtml('<b>' + name + '</b><br>#' + address1 + '<br>' + address);*/
            }
          }
        );
      }
    }

    
  
