How can I disable google maps completly

Home Forums Calendar Products Events Calendar PRO How can I disable google maps completly

Viewing 15 posts - 1 through 15 (of 17 total)
  • Author
    Posts
  • #1521008
    Martin Schmucki
    Participant

    Hi

    I disabled google maps in the settings but get an API error.
    How can I disable the service completly?

    Thanks,
    Chris

    #1521223
    Sky
    Keymaster

    Hi Chris!

    Thanks for reaching out! I will try to help with this.

    Can you provide a link to where the error can be seen, or a screenshot of the error?

    Thanks,
    Sky

    #1521643
    Martin Schmucki
    Participant

    Hi Sky

    It’s the “normal” Google Maps API error message that I didn’t set an API-Key.

    But the point is I don’t want Google Maps, I would like to disable this completly.

    Thanks,
    Chris

    #1522066
    Sky
    Keymaster

    Chris,

    In addition to unchecking “Enable Google Maps” can you try unchecking the “map view” in Events > Settings > Display > “Enable event views”

    Is the error still showing after that change?

    Thanks,
    Sky

    #1525072
    Martin Schmucki
    Participant

    No that’s not working :/

    #1525189
    Sky
    Keymaster

    Chris,

    Ok, thanks for checking. It looks like the script is enqueued even when all of that stuff is disabled.

    You can add the following to your functions.php to prevent the script from being loaded.


    wp_deregister_script( 'tribe-gmaps' );

    Let me know if that helps!

    Thanks,
    Sky

    #1525866
    Martin Schmucki
    Participant

    Hi Sky,

    I tried that solution but without success.

    My code looks like:

    add_action( 'wp_enqueue_scripts', 'my_deregister_javascript', 100 );
    function my_deregister_javascript() {
        wp_deregister_script( 'tribe-gmaps' );
    }

    Is the code wrong?

    Regards,
    Chris

    #1526138
    Sky
    Keymaster

    Chris,

    Yes, that code looks perfect. I apologize for not providing the complete code earlier. When I add that to my functions.php, I do not see the warning in the console any more. As soon as I remove the snippet and reload the page, the warning comes back.

    But I have the maps disabled in the settings as I described earlier.

    Where are you adding that code?

    Thanks,
    Sky

    #1529384
    Martin Schmucki
    Participant

    Hi Sky,

    I don’t know why but it doesn’t work :/

    And I disabled all views, only “List” is activated.

    Regards,
    Chris

    #1529614
    Sky
    Keymaster

    Chris,

    Interesting. You are putting this in your theme or child theme functions.php? Is there other code in there? Can you share with me the complete file?

    You might also try bumping the priority to 999, though I’m not sure why this would work on my end with it set to 100 and not for you.

    Thanks,
    Sky

    #1537731
    Martin Schmucki
    Participant

    Hi

    Sorry for the late response, but at the moment I’m overwhelmed with work ๐Ÿ˜‰

    I tried the code in both functions.php but haven’t any success.
    I don’t think it doesn’t work because the license isn’t registered?

    Can you maybe have a look at it, I can send you WordPress + the FTP-Login.

    Cheers,
    Chris

    #1538026
    Sky
    Keymaster

    Chris,

    Sorry to hear that you are not able to get this working. Unfortunately, it is against our terms of service to accept login credentials for customer sites.

    Can you provide a link to a page where the error is showing?

    Can you upload a copy of your child theme’s complete functions.php file?

    Also, can you provide your system information?

    Thanks,
    Sky

    #1551224
    Martin Schmucki
    Participant

    Hi again

    I found out if I clear this file:
    /events-calendar-pro/src/Tribe/Asset/Ajax_Maps.php

    The googlemap files doesn’t load, I tried this code in my functions.php:
    wp_deregister_script(‘tribe-gmaps’);
    wp_deregister_script(‘tribe-events-pro-geoloc’);

    But no success ๐Ÿ™
    I don’t know why -.-

    Any idea?

    Best Regards,
    Chris

    #1551738
    Sky
    Keymaster

    Hi again,

    Can you please provided the information I requested above?

    * link to a page where the error is showing

    * copy of your child themeโ€™s complete functions.php file

    * system information

    Thanks,
    Sky

    #1552118
    Martin Schmucki
    Participant

    This reply is private.

Viewing 15 posts - 1 through 15 (of 17 total)
  • The topic ‘How can I disable google maps completly’ is closed to new replies.