I am trying to:
I set up an address custom field for my CPT and I am trying to display that adress on a Google Map on the frontend.
It works just fine in one post but the map is empty in another post that is from the same CPT.
Additonally weird: In the post editor, when I enter the address, the marker is visible on the right spot every time.
Link to a page where the issue can be seen: hidden link
Go to "Trainers" and check the first post "Malwina F." where it is working fine. And then check "Raymond Chan" where it is not working.
I expected to see:
A marker on a google map pinned to an adress from the Address cutom field
Although it is working in some cases but not others, the most likely explanation is a problem with the API key and, specifically, the URL referrer restrictions.
First, I would test this editing the Google API key and removing any URL referrer restrictions.
I expect that the issue will then disappear if you re-test.
In which case you can add two API keys, the first with a URL referrer restriction for exposed client-based requests, and a second key with no URL referrer restrictions for unexposed server-based requests.