-
AuthorPosts
-
May 9, 2020 at 10:46 pm #1211523
Hi guys. I have searched for a solution among several recent threads on this, but I am still unable to make things work, and I’m afraid I need help.
We have been overriding the Enfold-themed version of The Events Calendar plug-in single event view on our site for a long time, using the method described here:
Unfortunately, somewhere in the mix of recent updates between Enfold and TEC, this has stopped working. I have spent the morning trying to fix it here with no luck.
The solution described in this thread which is to deactivate the Enfold theme modifications entirely does not work for us, because our site actually depends on the Enfold version of this template. We can’t just use the default TEC version.
I can “fix” the issue by directly modifying the PHP files in enfold/config-events-calendar/views, but of course that is fragile and will be undone on the next theme update.
Is there any way to get these overrides working again?
I’ve currently rolled TEC back to the last 4.x release because I at first thought the issue might have to do with 5.x updates. This didn’t seem to have an impact on things, so I can roll forward again if needed.
Thanks in advance.
May 15, 2020 at 8:28 am #1213170Hey Gary,
Thank you for the inquiry.
This is an issue with the updated calendar designs in the plugin. To fix the issue temporarily, you can either disable the said option (Use updated calendar designs) from the Events > Settings > Display (tab) or override the default-template.php file in the child theme.
Related threads:
// https://kriesi.at/support/topic/issues-with-events-calendar-and-events-calendar-pro/#post-1186624
// https://kriesi.at/support/topic/the-events-calender-new-design-venues-organisers-featured-imageBest regards,
IsmaelMay 15, 2020 at 8:37 am #1213178Thank you Ismael. You wrote:
This is an issue with the updated calendar designs in the plugin. To fix the issue temporarily, you can either disable the said option (Use updated calendar designs) from the Events > Settings > Display (tab) or override the default-template.php file in the child theme.
Are you suggesting the fix is to actually use the new calendar designs, or not to use these? I want to clarify that I never enabled the updated calendar designs in the first place, and as part of my troubleshooting I actually rolled back TEC to the last 4.x version prior to version 5, before they refactored all of their templates. I am still experiencing the issue which is why I am stumped.
Gary
May 18, 2020 at 9:49 am #1213961Hi,
The updated calendar designs option is going to be enabled by default once the plugin is updated and the issue probably occurs because this option changed the way how the templates are loaded, so the workaround is to disable the option or properly override the default-template.php file as described in the previous threads.
Thank you for your patience.
Best regards,
IsmaelMay 18, 2020 at 1:45 pm #1214035Alright, thank you Ismael. I’ll do some further investigating to see if I can make it work using the information referenced in the other threads. You can probably close this for now.
Gary
May 20, 2020 at 4:47 am #1214485Hi Gary,
Thanks for the update. Let’s keep this thread open in case you should need any further help on the topic.
Best regards,
RikardMay 25, 2020 at 7:53 pm #1216270Hi Rikard.
I’m afraid I’m back. I am still not having success getting the Event Calendar single event view and default template override to work, even after working through the discussion in the linked threads–which basically amounted to using the same method to override the default designs that I have been using all along.
First, I have confirmed that the new calendar designs in TEC are disabled. (There have never been enabled on my site.)
The problem seems to be that the following code, which has been in the functions.php of my Enfold Child theme for a long time, no longer seems to work:
/************************************************************* * Code supplied by Kriesi to override mods to The Event Calendar plug in single event PHP */ add_action('after_setup_theme', function() { if(is_child_theme()) remove_action('tribe_events_template', 'avia_events_tempalte_paths', 10, 2); } ); add_action('tribe_events_template', 'avia_events_template_paths_mod', 10, 2); function avia_events_template_paths_mod($file, $template) { $redirect = array('default-template.php', 'single-event.php'); if(in_array($template, $redirect)) { //$file = get_stylesheet_directory() . "/tribe-events/views/".$template; $file = get_stylesheet_directory() . "/tribe/events/v2/".$template; } return $file; }
No matter which directory path I point to for the overriden files, the theme continues to execute its default custom templates in /enfold/config-events-calendar/views.
I am stuck, because I cannot see what I am doing wrong–this code has worked reliably in the past.
Any further help would be appreciated.
May 29, 2020 at 8:33 am #1217607Hi,
Thank you for the update.
Did you try this step?
// https://kriesi.at/support/topic/issues-with-events-calendar-and-events-calendar-pro/#post-1186624
The default callback for the tribe_events_template hook will not work if the new calendar design is enabled. You can either disable the updated calendar designs from Events > Settings > Display (tab), or follow the instruction above and manually override the default-template.php file.
Best regards,
Ismael -
AuthorPosts
- You must be logged in to reply to this topic.