On Aug 3, 12:14 pm, joe <[email protected]> wrote:
>
> In my situation, StreetviewPanorama is only visible in Page B (the one
> in iframe)
> and <div id="pano"> is in Page A.
>
> So.. i have to write: var svobj = new google.maps.StreetviewPanorama
> (window.parent.document.getElementById("pano"));
>
> I suspect "StreetviewPanorama" or "setLocationAndPOV" doesn't like
> "window.parent".

If the containing page and the iframe are not both on the same domain,
this isn't going to work. Javascript's "same domain" actually means
the same subdomain: you can use document.domain to link subdomains
together.

Assuming they are and that cross-domain restrictions do not apply, you
then run into problems with passing complex objects between frames. It
would probably be best to load the API in the containing page and pass
only simple values from the iframe to a helper function in the
containing page which can create the panorama object.

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

Reply via email to