




  var map = null;
  var geocoder =null;




 function showAddress(adr, ville, pays) {

    if (geocoder) {
      geocoder.getLatLng(adr + " " + ville + " " + pays,
          function(point) {
            if (point) {
              var marker = new GMarker(point);
              map.addOverlay(marker);
            }
          }
        );
      }
    }
/*

    if (geocoder) {
      geocoder.getLatLng(adr1 + adr2,
          function(point) {
            if (point) {
              var marker = new GMarker(point, icon);
              GEvent.addListener(marker, "click", function() {
            marker.openInfoWindowHtml("<img src=\"http://<?=$_SERVER["HTTP_HOST"]?>/images/logo-gmaps.gif\" /> <strong>"+name+"</strong><br />"+adr1+"<br />"+adr2+"<br /><br /><a href=\"/un-magasin/"+id+","+namerw+".html\">détails</a>");
              });
              map.addOverlay(marker);
            }
          }
        );
      }
    }*/
  function centrecarte(adress) {
    if (geocoder) {
      geocoder.getLatLng(
          adress,
          function(point) {
            if (point) {
              map.setCenter(point, 13);
          }
        }
      );
    }
  }

  function initialize(adresse) {
    if (GBrowserIsCompatible()) {
      map = new GMap2(document.getElementById("carte-google"));
      map.addControl(new GSmallMapControl());
      map.addControl(new GMapTypeControl());
      geocoder = new GClientGeocoder();
      centrecarte(adresse);
      showAddress(adresse);
      //centrecarte("25, boulevard de Belleville","75011 Paris", "France");
      
      //showAddress("25, boulevard de Belleville" + " " + "75011 Paris" + " " +"France");

        
    }
  }
