Google Maps not displaying even with valid API Key and billing enabled

Hi,

recently Google Maps element stopped working. Following instructions on several other topics, I checked the Google API console and made sure that the key is linked to a working billing account. So that’s ruled out as an issue. Nevertheless, I still get an error.

The console shows this error:

It looks like the API-key entered on the editor, is not used on the frontend. I’ve searched through all the JS files, but did not found the API-key anywhere.
Where should the key be located in the source document?
Any other thoughts on what might cause this error?

Hi @dhunink,

Thanks for reaching out.
Can you please provide login credentials for your site in a secure note to examine it further, including:

– WordPress Site URL & Login URL
– WordPress Admin username/password
– Specific page where you have added the Map

To create a secure note, click the key icon underneath any of your posts.

Thanks

Hi @tristup,

I did some more testing, and I found the cause of the issue! I’m posting this publicly, so it could help others.
If you have the Map Element using Google Maps, but you also you another Google Places or Maps API on the same page, all those API’s will break. Actually, Google posts this in the console already, stating the JS API is used multiple times.

A temporary fix would be to delete the other API usage, as I did for now. The Map Element works again then.
But we still need a more robust fix. The Map Element should only insert and initiated the Google JS API, if it’s not already active on the page. Is this something worth forwarding to the DEV-team?

Hi @dhunink,

It is good to know that you were able to find the solution. I will surely convey your findings to our development team for further investigation on this.

Thanks

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