Wednesday, July 14, 2010

Re: Map with polyline from XML shows only in IE

On Jul 14, 1:28 pm, wfanning <williamlfann...@gmail.com> wrote:
> Hi,
>
> MS Internet Explorer displays this map with polyline overlay but
> Firefox and other browsers won't. Very simple (and brief!) html and
> javascript. Any suggestions?

Firefox doesn't know about "text" which is IE-specific; and GLatLng
takes numbers, not strings.

Try changing this
pts[i] = new GLatLng(lats[i].text,lons[i].text);
into
pts[i] = new
GLatLng(parseFloat(lats[i].textContent),parseFloat(lons[i].textContent));

--
You received this message because you are subscribed to the Google Groups "Google Maps API" group.
To post to this group, send email to google-maps-api@googlegroups.com.
To unsubscribe from this group, send email to google-maps-api+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-maps-api?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate