title: how to replace place marker with last click?
body: <p><strong>JS</strong></p>
  
  <pre><code>var map;
  
  function initialize()
  {
      var myCenter=new google.maps.LatLng(13.001294, 77.661736);
      var mapProp = {
    center:myCenter,
    zoom:15,
    mapTypeId:google.maps.MapTypeId.ROADMAP
    };
  
    map = new google.maps.Map(document.getElementById("googleMap"),mapProp);
  
    google.maps.event.addListener(map, 'click', function(event) {
      placeMarker(event.latLng);
    });
  }
  
  function placeMarker(location) {
    var marker = new google.maps.Marker({
      position: location,
      map: map,
    });
    document.getElementById("latt").innerHTML = location.lat();
    document.getElementById("long").innerHTML = location.lng();
  
  }
  
  google.maps.event.addDomListener(window, 'load', initialize);
  </code></pre>
  
  <p><strong>HTML</strong></p>
  
  <pre><code>&lt;div id="googleMap" style="width:500px;height:380px;"&gt;&lt;/div&gt;
  &lt;p id="latt"&gt;&lt;/p&gt;
  &lt;p id="long"&gt;&lt;/p&gt;
  </code></pre>
  
  <p>Here when we click on map more than one, there are number of place marker will appear. I want only one placemarker that last clicked place. How to fix that problem..? Thanks in advance.</p>