May 28, 2015 at 8:18 pm #37382
so, we are doing some testing. our staging site is accepting the value of 51236 (indiana) for a zipcode search, but the GWP plugin is placing it in Dnipropetrovsk Oblast (somewhere in Russia?)
same thing with other zipcodes. ohio zipcode is being located in saudi arabia. seems this just started happening.. not sure why. we have validation as well.. please see private content for URLS.. i encourage you to signup a dummy account and see for yourself. perhaps its a quick fix based on the admin side?Private Content HiddenMay 28, 2015 at 8:28 pm #37383
That is usually happens when a zipcodes ( in this case ), or city names exists in multiple countries in the world. In this case Google API cannot know to the zipcode of which country you are referring to and sometimes it will geocode the wrong zipcode.
Navigate to the admin dashboard -> GEO my WP -> Settings -> General Settings tab, check the Client-side geocoder checkbox and enter US in the country code input box.
Save the settings Test it again.May 30, 2015 at 7:26 am #37437
The country code box had the value US in it previous to the error. While we can enable the ‘auto locator’, our users and admin have found it to be annoying, so we disabled. perhaps its something that needs to be re-enabled.
we are trying to get users to simply enter in 1 field (a zipcode) for location. previous to this approach we had them enter in other qualifying fields.. eg address, city, etc. which would explain why this started happening… it actually happened before on our beta build back in January
my question is… if the country code box has been previously selected as US, and this is being sent with the form data to the API, why is it still returning international addresses?
note: we are using v 2.5, and while i realize there is an upgrade to 126.96.36.199, we are not ready to upgrade our plugin set until a newer initiative is completed. however i would like to ask… was the ‘US’ country code value changed or modified since v2.5? I’m guessing probably not.
I guess i can dig deeper into the admin side code in the geo-my-wp\includes\admin to see what value the US country code is sending off to the APIMay 30, 2015 at 11:06 am #37438
While we can enable the ‘auto locator’, our users and admin have found it to be annoying, so we disabled. perhaps its something that needs to be re-enabled.
For some reason when not using a client side geocoder Google API ignores the country code and can geocode the zipcode entered based on another country by default. When using Client-side geocoder Google API will look for and geocode the zipcode entered based on the country code.May 31, 2015 at 7:46 pm #37502
ah. the (lol) “autolocator” i was referring to is actually called “Google Address Autofill”
so there we have it.. two separate things. i think this issue should be resolved now
🙂June 14, 2015 at 12:08 am #38222
The topic ‘GWP zipcodes placing USA zips into international locations’ is closed to new replies.