Posted: January 6, 2018 at 5:20 pm
Hello, I have developed my site using X-Theme and the Cornerstone page editor. When inserting the calendar shortcode [ESPRESSO_CALENDAR] all I get are the drop-downs but no calendar. I tried inserting the code into a page without using cornerstone and the calendar worked ok. How can I resolve this issue to allow me to continue using cornerstone? Thanks, Ian |
|
Hi Ian, How are you adding the calendar shortcode within Cornerstone? In a text element? |
|
Hi Tony, Yes, I’ve inserted the shortcode into a text box but have also tried using the content box too with no joy. Any help would be greatly appreciated. Ian |
|
The calendar will only load its assets if EE has detected the shortcode is in use within the content, often page builders can confuse the tracking so the scripts are not loaded on the page. There are a couple of options to fixing this, the first is using this snippet: https://gist.github.com/joshfeck/a93625301ba269ce820214059064f2c6 On lines 6 through 9 the snippet changes for specific page IDs, you need to change those to the correct ID(s) you want the calendar script to load on, or use the page slugs, either is fine. The other option (which I don’t recommend over the above) is to load calendar scripts everywhere, you can do that using this snippet: https://gist.github.com/joshfeck/5d9c88fea504c0b111c3df8f24ad25d9 Add either of those functions to a Custom Functions Plugin on your site, set the page IDs/slug if using that function and the calendar should load. |
|
Hi Tony, I have tried this but still no calendar I am afraid. I created the Custom Functions Plugin using FileZilla and see that it is now available and editable within the Plugin Editor (code used below). When opening the page: http://www.messy-senses.co.uk/event-calendar/ All that loads are the filter drop-downs and the advertising text: Online event registration and ticketing powered by Event Espresso Have I missed anything? <?php add_action( ‘template_redirect’, ‘my_calendar_load_scripts’ ); /* Stop Adding Functions */ |
|
I have also tried the other code to load the calendar script across the whole site but with the same outcome. Do you have any other suggestions that will allow me to continue using X-Theme and Cornerstone? |
|
Is the code currently active right now? To confirm, is the ‘Site plugin for messy-senses.co.uk’ plugin activated on the site? |
|
Tony, thanks for the help, the plugin was deactivated so this resolved the issue 🙂 |
|
You’re most welcome, I’m glad it working for you now 🙂 |
|
The support post ‘Event Espresso Calendar in X-Theme using Cornerstone’ 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.