Feb 15, 2009 7:27 AM
GPS coordinates problem with maps
-
Like (0)
just having a bit of an issue with maps when using gps coordinates,
I've managed to get the gps coordinates for some locating using
google earth (decimal notation as opposed to degrees, minutes and
seconds). when I pop them into google maps, no problem I get the
exact location however when I use them as the address in the the
locations sub-sections I get some odd results, occasionally they
land where they should but often they keep landing on common
locations ie if I change the coordinates a bit the dot stays on the
same map location, I've tried clearing the geocache and even
removing and readding the locations but no luck. Any ideas?
Cheers
D
_______________________________________________
zenoss-users mailing list
zenoss-users@zenoss.org
http://lists.zenoss.org/mailman/listinfo/zenoss-users
"ian" wrote:
Well, you've exposed an excellent bug. Here's what was happening: the lat/long would be sent to Google for geocoding. Google would try to /reverse/ geocode it to an address, then /forward/ geocode the result, obtaining a set of coordinates that in no way necessarily correspond to the originals. I have no idea why it would do this, but that's my best guess as to what happened based on the geocoding responses.
Luckily, the fix is simple. There's no reason at all to send lat/lng coordinates for geocoding in the first place, so if the address of the Location is coordinates we can just skip that step. I've put the fix in the trunk:
http://dev.zenoss.org/trac/changeset/12202
Unfortunately the Google Maps code is quite a bit different in the trunk so you won't be able to apply the patch directly to an older version. You can manually apply it to the ZenGeoMap.geocode function, though. You'll need to make the change in geomap.js /and/ geomap-2.1.js. OR you can just wait for Blue Crab.
Let me know how it works out.
--Ian
Follow Us On Twitter »
|
Latest from the Zenoss Blog » | Community | Products | Services Resources | Customers Partners | About Us | ||
Copyright © 2005-2011 Zenoss, Inc.
|
||||||||