    var map = null;
    var geocoder = null;

    function load() {
      if (GBrowserIsCompatible()) {
        map = new GMap2(document.getElementById("map"));
        geocoder = new GClientGeocoder();
        
        showAddress("<?php echo $endereco; ?>", "<?php echo $nome; ?>", "<?php echo $html; ?>");
        
      }
    }

    function showAddress(address, caption, html) {
      if (geocoder) {
        geocoder.getLatLng(
          address,
          function(point) {
            if (!point) {
              alert("'"+address+"' nao encontrado no mapa!");
            } else {
              //var icon = new GIcon();
              //icon.image = "images/chinamarker.jpg";
              var icon = new GIcon(G_DEFAULT_ICON);
              icon.image = "http://www.google.com/intl/en_us/mapfiles/ms/micons/red-dot.png";
			  
              icon.iconSize = new GSize(30, 33);
              icon.iconAnchor = new GPoint(6, 20);
              icon.infoWindowAnchor = new GPoint(4, 1);
              map.addControl(new GSmallMapControl());
              map.addControl(new GMapTypeControl());
              map.setCenter(point, 16);
              var marker = new GMarker(point,icon);
              map.addOverlay(marker);
              GEvent.addListener(marker, "click", function() { marker.openInfoWindowHtml(html);});
              marker.openInfoWindowHtml(html);
            }
          }
        );
      }
    }