Remove Customizer Footer Styles

Home Forums Calendar Products Events Calendar PRO Remove Customizer Footer Styles

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1230411
    Cole
    Participant

    We are using your plugin on a large scale and are overriding a lot of styling from our own stylesheets. This is to control a lot of the look and feel without having to setup the customizer settings in each site. The issue is that there are two areas in the footer that appear to be outputting alot of Events Calendar styles from the customizer even when no customizer settings have been set. Is there a way to remove this CSS output in both places?

    tmpl-tribe_customizer_css and tribe_customizer_css are the two areas that are being output that are not needed.

    #1230893
    Cliff
    Member

    Hi. Thanks for your detailed request.

    Since it sounds like you’re familiar with code, please refer to https://github.com/moderntribe/tribe-common/pull/326/files

    In your case, you might want to just remove_action() for wp_print_footer_scripts

    Please let me know how this goes for you.

    #1230900
    Cole
    Participant

    This is what I have tried with no luck yet.

    function tribe_remove_customizer_style_tags() {
        if ( class_exists( 'Tribe__Events__Pro__Customizer__Main' ) ) {
            remove_action( 'wp_print_footer_scripts', array( Tribe__Events__Pro__Customizer__Main::instance(), 'print_css_template' ), 15 );
        }
    }
    add_action( 'init', 'tribe_remove_customizer_style_tags' );

    I also tried a simple

    remove_action( 'wp_print_footer_scripts', 'print_css_template', 15 );

    Sure it’s something simple missing. Appreciate your help on this.

    #1230933
    Cliff
    Member

    Your first snippet looks like the proper format (the second wouldn’t work).

    Regarding your first, please don’t use Tribe__Events__Pro__Customizer__Main as the Customizer settings have been moved to the core/free The Events Calendar plugin.

    Here’s a snippet for you:

    https://gist.github.com/cliffordp/d70d30c6278ffab2ad1db579dd421421

    Please let me know how this goes for you.

    #1232365
    Cole
    Participant

    Thank You. That seemed to work.

    #1232486
    Cliff
    Member

    Excellent. Thanks for confirming.

    Have a great day!

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Remove Customizer Footer Styles’ is closed to new replies.