I\'m using a modal popup when users click the map on this page here, which brings up a larger map with directions.
The map isn\'t filling the entire space however an
For completeness: if you're using Bootstrap modal window you need to use shown.bs.modal
event in place of shown
event.
Here the code:
$("#modalWindowId").on("shown.bs.modal", function(e) {
google.maps.event.trigger(map, "resize");
map.setCenter(markerLatLng); // Set here center map coordinates
});
Take a look here for learn more: http://coderpills.wordpress.com/2014/06/02/showing-google-map-inside-a-bootstrap-modal-window/