I think it's a problem with variable scope.

In your loadStreetView function you have:
var point = new GLatLng(place.Point.coordinates[1],
place.Point.coordinates[0]);

But that is defined within the return function of
geocoder_sv.getLocations so is only visible within that function.

Then you have:
panoramaOptions = { latlng: point };

But this will not be using the point variable defined above, but the
one from:
point = new GLatLng(place.Point.coordinates[1], in the load function,
which will always be the last address geocoded on load.

I think as you don't actually var that point variable it is
automatically global.

--~--~---------~--~----~------------~-------~--~----~
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