Upon testing the feasibility of switching to Event Espresso, I’m encountering an issue with the Onetone theme.
On our site, the calendar shortcode/tag does not produce a result if included in the one page homepage of the theme. It’s there, in the source code, but without width and height and not populated. Including the tag on a regular WordPress page shows the calendar without any problem.
Searching the forum, I found a number of references to Javascript errors, but couldn’t find that causing the problem at hand.
Using: EE4 and WordPress 4.4.
Do you have any advice as to what might cause this behavior?
What happens is if the shortcode is being added through an options panel, like in the case of the Onetone homepage, then the shortcode’s necessary scripts and styles will not load.
One way to work around this is add something like this to your functions.php file:
function onetone_load_calendar_scripts_on_homepage() {
if (is_front_page()){
global $is_espresso_calendar;
$is_espresso_calendar = TRUE;
}
}
add_action('wp_enqueue_scripts', 'onetone_load_calendar_scripts_on_homepage');
You can add the above to a functions plugin or into your WordPress theme’s functions.php file. We recommend using a child theme if you add to the functions.php file.
Unfortunately, I still encounter a problem. In case I want to load a second instance of the calendar using the shortcode, it doesn’t load the 2nd instance.
Thank you for pointing this out, however I was hoping for a solution of course
Is there anything to do about this? Although it might seem uncommon, it’s relevant to our website to be able to display the calendar twice.
The support post ‘Calendar not showing on parallax home page, working fine on regular page’ 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.
Support forum for Event Espresso 3 and Event Espresso 4.