Closed saltymouse closed 4 years ago
Hey @saltymouse, How are you entering the address in the field?
When I enter it like this, it seems to get the correct coordinates.
Hi Jan, thanks for the the reply.
Indeed, I had entered the address just as your screenshot shows. However, I think I may have solved the issue after playing around with it for a bit.
I got the same address (above) to produce the correct coordinates only after clearing both the latitude and longitude fields, then re-saving the Craft entry (thus generating new coordinates based on the address fields). It looks like the coordinates aren't refreshed unless cleared-out first (then re-saved). Is this correct?
I was under the impression the coordinates would regenerate upon each save regardless of whether or not there were old values in there. My problem was: I had set the coordinates fields to hidden (in the field's settings) so I didn't realize I could empty them to begin with.
If this is working as expected, I think it might be useful to make note of this refresh method in the README somewhere. If not, perhaps a refresh button, or just regenerate the coordinates upon each Craft entry save.
Hey there
That is indeed correct, the coordinates are only looked up on the first save, to not make repeated requests (= costs) to the geocoding API.
And you're also correct that that should be in the readme, I'll get on that right away!
If you have any other questions, feel free to reach out!
I'm using the plugin to get the geocode coordinates from addresses for Leaflet maps on the front end. This works great, but one of the addresses I have is geocoded incorrectly. Is there any way to debug the geocoding process to see why this is happening?
I've enabled the geocoding API on my Google account, and it works for all other addresses. Here's an example address that isn't working for me: 19510 144th Ave NE Suite A-6, Woodinville, WA 98072
In the Easy Address Field plugin, this generates a coordinate in Nebraska, not Washington state.
Entering this same address into Google's online geocoder demo, however, shows the correct address location in WA: https://developers.google.com/maps/documentation/javascript/examples/geocoding-simple