動態改變Google Map的大小(以高度為例)
function resizeMap(size){//
var mid = document.getElementById('map_canvas');
mid.style.height = size + 'px';
if(map != null) {
google.maps.event.trigger(map, 'resize');
}
}
Comments