Posted: November 11, 2020 at 9:07 am
Hi, |
|
Hi there, A lot of the output of the events/venues is controlled by your, we hook in and add the event details but it’s actually your theme that outputs things like the featured image. We’ve seen other themes in the past only display certain features for specific post types which may be happening here. Can you send me a copy of the theme so I can take a quick looks? If they have a hook I can use to alter this I should be able to give you a snippet to fix it. |
|
Thanks for your reply Tony. I’ve only recently taken over managing the website and am still learning… how do I send a copy of the theme? Thanks |
|
So, assuming the Alone theme is a one from ThemeForest HERE them I’m guessing you don’t have the login details for ThemeForest to download the .zip file from there? |
|
Hi Tony, I’m just waiting on the details from the developer who created our website, I’ll update once I’ve got them. Thanks |
|
Ok, thank you. The |
|
Hi Tony, I’ve got the .zip file now. How do I send it to you? Thanks |
|
You’ll need to either host the file somewhere (upload it to the site for example) and post a link to download here. Or, use something like WeTransfer to send a copy to support[at]eventespresso.com |
|
Thanks, I’ve sent it with WeTransfer |
|
Hi there, On installing your theme, my site shows the featured image on EE events just fine. Looking at your events the feature image is loading but there’s some styles to hide it in your theme, you can override them using something like:
You can add that to Appearance -> Customize -> Additional CSS. |
|
Thanks, I’ve added this now and can see the featured image although it’s below the grey header where I was hoping it would be. Is there any way to add an image in the header of the page so that it ties in with the other pages on the website or is this not possible for events? |
|
Alone theme looks like it limits the features available if you don’t have a valid key, so I can’t see how the pages are created on the site as is. Looking at the source code from your site it looks like its using visual composer and if thats the case you can’t use it within EE events to output the same content. Can you add a screenshot of how you set the feature images to load on normal pages? |
|
So we use two different approaches depending on whether it is a blog or a page, I’ve sent you screenshots of both options. I was hoping with EE it would work in a similar way to the blog posts where we set both a featured image and a header image but it appears there is no option for a header image in EE? |
|
In short, that’s all custom to your theme and the ‘header_image’ isn’t being added to EE’s editor by your theme so it can’t work like normal posts. What you could do is hook into the save_post hook and save the values from the feature image set on the post into the settings used by the theme. How comfortable with PHP are you? |
|
Unfortunately I don’t know any PHP! |
|
I spent some time looking over this on the weekend as I was curious and have a snippet that uses the feature image set on EE Events/Venues to set the options values that the theme is expecting. Before you use this I should note that this snippet is unsupported and if you run into further issues with the the feature image you’ll need to contact the theme author as its the theme and not Event Espresso. Are you using a child theme? If so, add this to your child themes https://gist.github.com/Pebblo/8cd7cbe214e3fc36cec2f17f3c931de4 If not you can create a custom functions plugin to use it and we have documentation on creating one here: https://eventespresso.com/wiki/create-site-specific-plugin-wordpress-site/ Once you have that code on your site, edit an event and set a feature image on it, if you already have one set, just save the event (it updates the theme settings for that event on save). Then confirm it works as intended. |
|
Hi Tony, Thanks so much for your help on this. The alone-child folder doesn’t contain a functions.php file, only the alone folder. I take it this means we’re not using a child theme so I need to go down the custom functions plugin route? Thanks |
|
You can do either, you’ll need to set up the child theme with a functions.php file and then activate the child on the site: https://developer.wordpress.org/themes/advanced-topics/child-themes/ Or set up the custom functions plugin as above. If the above snippet is the only one change you are making to the theme’s output then using a custom functions plugin is fine. |
|
Thank you so much – I’ve implemented a custom function plugin and it’s working now. |
|
You’re most welcome 🙂 |
|
The support post ‘Featured image not displaying on Event’ 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.