If an address is entered and the latitude/longitude are cleared or the map marker is removed, we should attempt to geocode again. This patch does that, and also updates the instructions to reflect that.
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | location-regeocode.patch | 4.3 KB | scottgifford |
| #3 | location-2.3.x.patch | 5.77 KB | nicholasthompson |
| location-2.patch | 5.89 KB | scottgifford |
Comments
Comment #1
scottgifford commentedThis patch also causes geocoded locations to be shown on the map, which we found useful for verifying the geocoding was correct.
Comment #2
scottgifford commentedChanged status to patch, since there is a patch attached.
Comment #3
nicholasthompsonThis is the same patch but I had to re-roll is as it looks like you did it to a different version to the current 3.x release...
Thanks for the patch, worked a treat on my setup.
Comment #4
nicholasthompsonActually, I've been testing and this section that you added...
... confuses me.
It breaks my site in that if I add a node with an address and this address is sent to Google for geocoding and google turns around and says "thats not a valid address" then these lines stop the record getting stored so I end up with a bunch of empty location fields.
Comment #5
scottgifford commentedNicholas,
You are right, that doesn't work how I thought it would. Does it work for you if you just remove those lines?
I'll take a closer look at the code and see what I can figure out.
Comment #6
nicholasthompsonI believe so, I'm just retesting my dataset now... I foolishy made a script to go through and programaticaly submit each node to update the long-lat vals... I didn't expect to get all the locations wiped, so I'm reimporting the data again.
Its no big deal as its only a dev server. Learned my lesson though ;-)
Comment #7
scottgifford commentedYes, it looks like your change to my patch was correct. Thanks, and sorry I wiped all your location data!
If everything works for you, could you roll a new patch and post it here? I have other changes to my location.module and it's time-consuming to untangle the ones that are just for this change. Thanks!
Comment #8
scottgifford commentedHere is an updated patch against 5.x-3.0-test2 which addresses the problem reported by nicholasThompson.
Comment #9
bdragon commentedFixed in DRUPAL-5--3 and HEAD in a different way than the patch, and simplified some of the code at the same time.
http://drupal.org/cvs?commit=138981
Comment #10
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.