Recurring event pages (/all/) not recognized as calendar pages

Home Forums Calendar Products Events Calendar PRO Recurring event pages (/all/) not recognized as calendar pages

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #1048606
    Sean
    Participant

    The problem: The sidebar doesn’t display on recurring event pages (the page that shows ALL events in the series, e.g /event/example-recurring-event-title/all/), but it shows up on every other TEC page.

    More info: The function ​is_events_archive()​ returns false for these pages, so the theme doesn’t detect this as an Events Calendar page, so it doesn’t display the sidebar set in the corresponding section in the theme settings. You might say that this isn’t an archive, but ​is_singular(“tribe_events”)​ doesn’t return true either. As a result, the /all/ pages aren’t detected by the theme (in our case, Avada) as a single Event Calendar event page either.

    Hope you can address this in a future maitenance release. Thanks.

    #1050585
    Brian
    Member

    Hi Again,

    Sorry for all the issues you are having.

    Thanks for bringing them up though.

    I found the tribe_is_recurring_event() works on this page so there is at least some way to target it.

    I have created a bug ticket for us to look into changing how it is created and my suggestion is to match single event template so if you have a sidebar in the single event it should show here as well.

    Thanks

    #1050631
    Sean
    Participant

    Hi Brian,

    Thanks for recording this. Can you please clarify what the workaround in the meantime is? We do have a sidebar on our single event template, but I don’t follow what you suggested above. Thanks for your help.

    #1050671
    Brian
    Member

    That is just a conditional check.

    if ( tribe_is_recurring_event() ) {

    //enter coding

    }

    Not sure how your theme works and that “page” is working to add it and it might just target all Recurring Events too.

    It might have to be something like this:

    if ( tribe_is_recurring_event() && ! is_singular( ‘tribe_events’ ) ) {

    //enter coding

    }

    #1050733
    Sean
    Participant

    Thanks again Brian. I’m not a coder (the developer I hired for a project last month had pointed this issue out to me) so I’ll need to find some additional help in how to apply this conditional to our use case. I’m guessing that once we determine what the exact coding for the conditional statement is, it needs to be added to our functions.php?

    #1050820
    Brian
    Member

    More likely it will have to be added into a template and not into the functions.php.

    #1051395
    Sean
    Participant

    Okay great thanks again Brian.

    In case this helps anyone else using Avada, we added the following to /Avada/includes/class-avada-layout.php which got the sidebar appearing on the /all/ pages.

    		if ( tribe_is_recurring_event() && ! is_singular( ‘tribe_events’ ) ) {
    			$sidebars = array(
    				'global'    => '1',
    				'sidebar_1' => Avada()->settings->get( 'ec_sidebar' ),
    				'sidebar_2' => Avada()->settings->get( 'ec_sidebar_2' ),
    				'position'  => Avada()->settings->get( 'ec_sidebar_pos' ),
    			);
    		}
    #1051427
    Brian
    Member

    Great, glad you got it and thanks for sharing!

    I am going to go ahead and close this ticket, but if you need help on this or something else please post a new ticket.

    Thanks!

    #1077134
    Geoff
    Member

    Hey there, Karly!

    Just wanted to jump in here and let you know that we released The Events Calendar 4.0.6 last night and it included a fix for this issue. Please check your WordPress updates, or you can also grab the latest copy over at WordPress.org.

    Thanks for your patience while we worked on this! Please feel free to open a new thread if you continue to experience the same issue or have any other questions that pop up during updating and we’d be happy to help. 🙂

    Cheers!
    Geoff

Viewing 9 posts - 1 through 9 (of 9 total)
  • The topic ‘Recurring event pages (/all/) not recognized as calendar pages’ is closed to new replies.