Google Map API Code

Hi how the hell do you add a Google Map API code in this theme? I built a site with this two years back and I cant remember how to do this? It worked originally but now its stopped. It was done originally with shortcodes which after updating no longer work!
I tried calling the map in the functions file with the api key as a parameter but that wont work and there’s nothing useful I can find online… please don’t tell me I have to use that cornerstone thing.

Jimmy

Hi Jimmy,

Thanks for writing in! To use the Map shortcode, please refer to the following guide (http://demo.theme.co/integrity-1/shortcodes/map/) and you can simply add the API Key to your Map shortocde as an additional parameter as mentioned below.
[x_map api_key="xxxxxx"][/x_map]

Recently Google Maps API also have changed with some updates which requires a billing account now. Please refer to the following tutorial on how to setup your Google Maps API (https://www.youtube.com/watch?v=HS0j0aMvnoU).

Hope that helps.

Hi thanks for the help. I think its a script mismatch because I’m getting an “OOPS something went wrong” grey screen after the correctly created map flashes up briefly when I look in the console I get a host of jquery errors but no Google Map js errors? I checked my shortcode and it looks clean.
Theme version 6.4.6

[x_google_map api_key="my-api-key" lat="52.21939" lng="-7.15334" drag="true" zoom="10" zoom_control="true" no_container="true" width="1200px" hue="#c5d6e5"] x_google_map_marker lat="52.36690" lng="-6.44833" info="A Name " image="https://mysite.com/construct/wp-content/uploads/2017/04/map-marker.png"]
[/x_google_map]

J

Hi Jimmy,

Did you replace the my-api-key with your Google API?

Please also check you’ve already turned off the restriction of API:

https://developers.google.com/maps/documentation/embed/get-api-key#key-restrictions

Let us know how it goes!

Hi, yep the real key is there and I have restricted the usage to the domain.

J

It was a Google API billing issue there was no linked account. But there was none of the normal messages associated with it for some reason.
Thanks

J

Glad you’ve sorted it out.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.