CPT conditionals for filters

Home Forums Calendar Products Events Calendar PRO CPT conditionals for filters

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #53834
    Cinch
    Participant

    I use conditionals to filter the the page layout… Using the previous version of ECP, the following conditionals worked (the third one still does):

    function infusion_one_column() {
    if ( get_post_type() == 'tribe_events' )
    add_filter( 'theme_mod_theme_layout', 'infusion_layout_1c' );
    elseif ( is_post_type_archive( array( 'tribe_events') ) )
    add_filter( 'theme_mod_theme_layout', 'infusion_layout_1c' );
    elseif ( is_tax( array( 'tribe_events_cat' ) ) )
    add_filter( 'theme_mod_theme_layout', 'infusion_layout_1c' );
    }

    Any idea why these conditionals stopped working?

    #53880
    Jonah
    Participant

    Hi Bryan,

    What event related pages specifically were you targeting with the above conditional?

    #53882
    Cinch
    Participant

    Hi Jonah,
    The main calendar page and a singular event.

    Thanks.

    #54071
    Jonah
    Participant

    Hey Bryan,

    Not sure why your code is not working anymore but please take a look at these conditionals that I’ve put together and tested with 3.0: https://gist.github.com/jo-snips/2415009

    That should work for you but let me know if you have any other questions.

    Regards,
    Jonah

    #980221
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘CPT conditionals for filters’ is closed to new replies.