How do I resize a Google Map with JavaScript after it has loaded?
Posted
by Matthew James Taylor
on Stack Overflow
See other posts from Stack Overflow
or by Matthew James Taylor
Published on 2009-04-13T06:54:46Z
Indexed on
2010/03/31
2:13 UTC
Read the original article
Hit count: 444
I have a 'mapwrap' div set to 400px x 400px and inside that I have a Google 'map' set to 100% x 100%. So the map loads at 400 x 400px, then with JavaScript I resize the 'mapwrap' to 100% x 100% of the screen - the google map resizes to the whole screen as I expected but tiles start disappearing before the right hand edge of the page.
Is there a simple function I can call to cause the Google map to re-adjust to the larger size 'mapwrap' div?
© Stack Overflow or respective owner