Forum Replies Created
-
AuthorPosts
-
eclairParticipant
Thanks! Trying to add a venue manually this way (I normally add venues through the Events page), I was able to see that there was an error about the API access has exceeded (because I’m on a shared server). Looking into the code, I found in /events-calendar-pro/src/Tribe/Geo_Loc.php the code that calls Google Maps API.
So I modified line 439 to this:
$url = 'https://maps.googleapis.com/maps/api/geocode/json?address=' . urlencode( $address ) . '&key=[API_KEY]';
Where [API_KEY] is a server key generated with Google.
I also had to make the protocol from http to https.
Now I’m able to generate the proper lat/lon coordinates.
I would like to suggest adding this into your code for future updates (with the proper configuration option in the admin settings screen, of course!)
Now that that is working, I just basically modified your code to force it to look up all the lat/lon coordinates for every venue and save all the data again, and now it seems to be working much better!
eclairParticipantExactly the same as your video, except at the end, when I click on Use Lat/Lon again, I don’t see the coordinates pre-populated.
eclairParticipantHi, thanks George. It seems when I click Use Lat/Lon, the page prompts me for the Lat/Lon of the venue, and if I try to save the page without entering the values for them, the setting to use Lat/Lon doesn’t stick.
Do I have to manually provide the coordinates for each venue?
eclairParticipantThanks Barry… So far the change is working well… Functionality seems to be fine as well (doesn’t look like anything broke in the process). Thanks very much for this fix. Definitely try to incorporate this change in your next release! 🙂
eclairParticipantLooks good so far… Much faster, and I don’t see the multiple queries for the same thing. I will test it out a bit further and play around with it and let you know!
eclairParticipantThanks Barry, I’ll give it a test and I’ll let you know what happens. We’re hitting Thanksgiving, so it might be a couple of days. Thanks for your prompt response!
-
AuthorPosts