Posted: September 6, 2023 at 1:25 pm
I have customized the espresso-events-table-template.template.php file and moved iot to my child theme. When I use the ESPRESSO_EVENTS_TABLE_TEMPLATE shortcode in my theme files it works great. But when I add the shortcode to the backend page editor, it does not use the customized template. The exact shortcode I am using in both places is: I’ve tried inlcuding the template_file parameter to call the custom template directly, but that does not change anything. The shortcode uses the custom template file just fine without that parameter when I use it in a theme file. I am using the latest version of EE: 5.0.10.p |
|
If you take a look here: https://eventespresso.com/wiki/events-table-view-template-add-on/ There are instructions on how to load a custom template form your themes root directory, plz try those, customize the template and confirm if it loads using the shortcode on a page. thanks. |
|
Yes, those are the instructions I followed. Again, my custom template loads correctly when I add the shortcode to a theme file like a page template, but it does not work when I add the shotcode using the WordPress page editor. In that case, the event table works, but it does not load the custom template. |
|
Hi Laurel, Just to clarify something above, when your using the shortcode within your theme your using do_shortcode(), correct? so:
This is odd! Using the standard WP editor correct? (I assume so based on your reply but just checking) Can you add a screenshot? Looking over your site it looks like your using visual composer? Does it not load the template on the front end either? |
|
Hi Tony, Yes, the site uses visual composer/WP Bakery – I should have mentioned that. Here is a link to a page where the same shortcode is being used in a text editor block: https://yesempower.com/coach-training-academy/ The two tables look fairly similar, but the key change I made to the custom event template (seen in the screenshot) is the Register link opens the event details in a modal window. |
|
Hi Tony, Yes, the site uses visual composer/WP Bakery – I should have mentioned that. Here is a link to a page where the same shortcode is being used in a text editor block: https://yesempower.com/coach-training-academy/ The two tables look fairly similar, but the key change I made to the custom event template (seen in the screenshot) is the Register link opens the event details in a modal window. |
|
Hi Laurel, So I’d like to take a deeper look at this and add some debug code within both the Table View Template and Event Espresso to try and get a better view of what is going on. I can’t reproduce this locally even when using Visual Composer, so I’d like to output the details within the methods used to locate the template file and see where this is breaking down. If that’s ok, I’ll need WP-Admin and FTP credentials which you can send over using this form: https://eventespresso.com/send-login-details/ If you can create a new page with the shortcode on that I can view/work on this outside of your ‘normal’ pages that’d be great. |
|
This reply has been marked as private. | |
Hi there, Thank you for sending over the login credentials, I have responded directly via email. I need to be able to add some debug code to the site and for that, I’ll need FTP access. If you can resubmit the form with those details included I can then check into this. |
|
Thanks for your help with this Tony! The issue was with some code in my custom event template that was restricting it to only work on certain pages. Tony was able to point out the problem and it is working well now so I’m marking this as resolved. Thanks again! |
|
The support post ‘ESPRESSO_EVENTS_TABLE_TEMPLATE – custom template not loading’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.