Re: [Google Maps API v3] IE7 can't show the map when there's another div with an absolute position

58 views
Skip to first unread message
Message has been deleted

Mike Williams

unread,
Sep 19, 2009, 5:01:30 AM9/19/09
to google-map...@googlegroups.com
For the record, MSIE6 crashes deep inside main.js when trying to perform
a.width=b, where b has the value "-10px". MSIE6 doesn't seem to permit
styles to have negative width.

The crash happens during an extremely obscure bit of JS code that might
possibly be processing the controls.

--
Mike Williams
Gentleman of Leisure

Message has been deleted

Mike Williams

unread,
Sep 19, 2009, 6:33:31 AM9/19/09
to google-map...@googlegroups.com
I'm just telling you what happens to that page in MSIE6, in case you
don't have access to that browser. The negative width isn't coming from
your code directly, the API seems to be calculating it somehow.

Firefox, Chrome, Opera and Safari simply ignore any attempts to apply a
negative width style to an element. MSIE6 crashes.

[MSIE7 doesn't work on my computer, and I've not tried installing
MSIE8.]

Perhaps MSIE8 ignores the negative width setting, but MSIE7 gets
confused.

Have you looked to see if MSIE7 has an "Invalid argument on line 1"
error in its error log.

Message has been deleted

Esa

unread,
Sep 19, 2009, 8:03:30 AM9/19/09
to Google Maps JavaScript API v3
You have strict doctype and sizing of the map div like:

#map{
position:absolute;
top:125px;
bottom:20px;
left:20px;
right:200px;
background-color: teal;
}

My theory is that IE has trouble using bottom:20px; because it does
not know the height of the parent element.

I would try the old trick, originally presented by Mike:

html, body {height: 100%}
Reply all
Reply to author
Forward
Message has been deleted
0 new messages