Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #832968

    Hi,

    we used to have a Google Map on a website. But for some weeks now, we are getting an API error:
    RefererNotAllowedMapError https://developers.google.com/maps/documentation/javascript/error-messages#referer-not-allowed-map-error

    I tried generating new API Keys, new Projects, removed all Referer information… nothing helped :(
    Enfold also shows a error when trying to fetch coordinates in the backend.

    The client ist getting impatient and I have no further ideas about how to solve this.

    I really hope you can help me figure this out.

    #832978

    Hi 2SINN!

    Please remove following code from Functions.php file of your child theme

    /* Temp Google Maps Fix */
    
    function ava_googlemaps_apikey() {
    	$prefix  = is_ssl() ? "https" : "http";
        wp_deregister_script('avia-google-maps-api');
    	wp_register_script( 'avia-google-maps-api', $prefix.'://maps.google.com/maps/api/js?key=AIzaSyAidX34J-pkIHmOUFdVrt05MpzDHz-VZUk', array('jquery'), '3', true);
    	wp_enqueue_script('avia-google-maps-api');
    }
    add_action('init', 'ava_googlemaps_apikey');

    Cheers!
    Yigit

    #832982

    Thank you so much, Yigit! Sometimes you just need another pair of eyes to see the obvious!

    #833023

    Hi,

    You are welcome! :)

    For your information, you can take a look at Enfold documentation here – http://kriesi.at/documentation/enfold/
    And if there are features that you wish Enfold had, you can request them and vote the requested ones here – https://kriesi.at/support/enfold-feature-requests/
    For any other questions or issues, feel free to post them here on the forum and we will gladly try to help you :)

    Best regards,
    Yigit

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Google Maps API Issues’ is closed to new replies.