testes com google maps api v3

localizaçao automatica, marker, zoom, width/height com porcentagem, centralizaçao automatica ao redimensionar e ao mover o marker, infowindow

HTML

<script src="https://maps.googleapis.com/maps/api/js"></script>
   <div id="map" style="width: 500px; height: 350px;"></div>

CSS

#map{border:2px solid blue;}

JavaScript

var map;

function initialize(location) {

var currentPosition = new google.maps.LatLng(14.457264, 121.024038);
var mapOptions = {
  center: currentPosition,
  zoom: 12,
  mapTypeId: google.maps.MapTypeId.ROADMAP,
};

map = new google.maps.Map(document.getElementById("map"), mapOptions)

var marker = new google.maps.Marker({
  position: currentPosition,
  map: map
});
  google.maps.event.addListenerOnce(map, 'idle', function(){
      
   var bounds = map.getBounds();
   alert(bounds);
});
}
google.maps.event.addDomListener(window, 'load', initialize);