Support

Home Forums Event Espresso Premium Theme conflict

Theme conflict

Posted: July 31, 2017 at 5:13 am

Viewing 21 reply threads


whoon

July 31, 2017 at 5:13 am

Hello,

I just installed the EE4 plug-in and found out i have an theme conflict (i think).
We are using https://themeforest.net/item/shopping-mall-entertainment-shopping-center-business-wordpress-theme/14351773?s_rank=1 tamplate.

With Twenty Seventeen template it is working. I thought it was working with the Decaf version too, but not 100% sure.

Can you help me? I have made a temp admin account for you if needed.

Regards,

Jeffrey Happel


Josh

  • Support Staff

July 31, 2017 at 11:54 am

Hi Jeffrey,

We’ll actually need a copy of the theme to investigate its code and find the conflict. Can you upload the theme somewhere then post a link so we can download it?


whoon

August 1, 2017 at 1:14 am

Hi Josh,

Yes ofcourse, is there a way to send it to you in a private msg? It is a paid theme so dont really want to post it publicly!

Regards,

Jeffrey


Tony

  • Support Staff

August 1, 2017 at 5:31 am

You’ll need to host the zip somewhere (Dropbox or WeTransfer for example) and email a link to support[at]eventespresso.com

If you include the zip file within the email itself it will likely be rejected based on filesize.


whoon

August 1, 2017 at 5:40 am

The email with link is sent, thank you!


Tony

  • Support Staff

August 1, 2017 at 7:28 am

Thank you, can you provide some details on how to reproduce the problem?


whoon

August 1, 2017 at 7:31 am

Yes ofcourse, I made an event with all the details.
When browsing to the event page (/event/name/) it doesnt show any event details, just the comment section. Also i think the /event page isnt displayed correct.

Regards,

Jeffrey


Tony

  • Support Staff

August 1, 2017 at 7:48 am

Do you have anything set within the event content?

If not add something, it doesn’t matter what, update the event and retest, does it work then? – http://take.ms/ecyu5

The theme is using get_the_content() to confirm if it should call the_content(), if you don’t have anything set within the event content section the theme doesn’t call the_content() which is where EE adds all of the event details.

Also i think the /event page isnt displayed correct.

It’s actually displaying how your theme expects, it’s not really a conflict but how the theme outputs post archives.

Are you working with a developer? Both of the above can be fixed by loading your own custom templates in place of the originals using a child theme but looking over the code for the theme you’ll likely run into similar issues throughout and will need various ‘fixes’.


whoon

August 1, 2017 at 7:59 am

If i set the content it does show something indeed, thank you! 😀

Do you have the code of how it is displayed in the demo? I can put that in our template myself i think!

Regards,

Jeffrey


Tony

  • Support Staff

August 1, 2017 at 11:57 am

You need to create a child theme, here is a tutorial for doing so:

https://www.smashingmagazine.com/2016/01/create-customize-wordpress-child-theme/

Copy the archive.php from your parent theme to the child theme and rename the copy to archive-espresso_events.php (and archive template only used for EE events).

Then change this code:

if (theme_excerpt(55, false) != '') {
	echo cmsmasters_divpdel('<div class="cmsmasters_archive_item_content entry-content">' . "\n" . 
	wpautop(theme_excerpt(55, false)) . 
'</div>' . "\n");
}

To:

echo cmsmasters_divpdel('<div class="cmsmasters_archive_item_content entry-content">' . "\n" . 
the_content() . 
'</div>' . "\n");

(Yes remove the if statement using theme_excerpt() completely)

When using archive-espresso_events.php Event Espresso assumes you are taking full control of the output, in your case you are not, just removing strange things the theme is doing, so you need to tell EE to continue to inject the event details, you do that by adding:

//Filter to force Event Espresso to continue to inject event details into the content when using arachive-espresso_events.php
add_filter( 'FHEE__EED_Event_Archive__template_include__allow_custom_selected_template', '__return_true' );

To your child themes functions.php file.

Note to confirm this worked I ended up creating a child theme and testing this, so you can review/use that if you prefer (it actually also has a fix for the ’empty’ event content too): http://take.ms/Ba0G9

However, note that the above should be considered untested and unsupported as we do not provide support for themes and was just something I used to confirm the above.


whoon

August 2, 2017 at 2:01 am

Hello,

I have tried this and although it does work now i still don’t really like the look, pretty messy.

I was looking at your use cases and that is way better, isnt there a way to make it look like that with the archive-espresso_events.php file?

Hope to hear from you soon.

Regards,
Jeffrey


Tony

  • Support Staff

August 2, 2017 at 2:40 am

It all depends on your theme.

Yes, you can edit archive-espresso_events.php to output the event list however you prefer but again the output is controlled completely by your current theme. The use case you have looked at will be using a theme that outputs the archives in a ‘better’ way than your current theme.

Which use cases were you looking at?


whoon

August 2, 2017 at 2:44 am

Ok, i was looking at the use-cases page and like the way that is displayed, this isnt priority though as we only have 1 event for now.

The use case layout i’d like is from this event http://demoee.org/use-cases/events/countryside-high-school-class-of-2005-reunion/

I think it is pretty default but way better then the one we have in our template, there must be a way to overwrite the event layout too?

Regards,

Jeffrey


Tony

  • Support Staff

August 2, 2017 at 3:07 am

What is it you want to override?

The page you linked to has a feature image and a sidebar, the rest of the details are added by to the page default. If you add a venue to your event you’ll get the same details shown on your event.

Yes you can override the single event view using a single-espresso_events.php template (a copy of your themes single.php) but I’m not really sure you need to based on comparing your event with the link you provided.


whoon

August 2, 2017 at 3:19 am

I think it is mostly style which i have to modify, will figure that out myself in the css. The main thing is on my event the featured image doesnt show and the text shows under the ticket details instead of above. The other things are styling i guess, no tables as an example. With the editing of the single.php ill probably manage to fix the text, how can i display the feature image there?


Tony

  • Support Staff

August 2, 2017 at 4:22 am

To get the featured image to show you use the the_post_thumbnail() function within your template.

Within the child theme I provided above look within mall-child\framework\postType\blog\post

You’ll find a standard.php template file that is used to output the post details throughout your site. If you only want the feature image to display on EE single event posts, you can add something like this:

if ( '' !== get_the_post_thumbnail() && get_post_type() == 'espresso_events' && is_single()  ) { ?>
	<div class="post-thumbnail">
		<a href="<?php the_permalink(); ?>">
			<?php the_post_thumbnail(); ?>
		</a>
	</div><!-- .post-thumbnail -->
<?php }

Where exactly you place it depends on where you want the image to display, just after line 45 should work.


whoon

August 2, 2017 at 5:39 am

Thank you, i got the featured image working and the text on the right place, some style issues left now but those will be fine, thank you for the help!

Regards,

Jeffrey


Tony

  • Support Staff

August 2, 2017 at 9:27 am

You’re most welcome.


whoon

August 3, 2017 at 1:25 am

We do have another problem now, the plug-in isnt sending out emails. We are using an smtp plug-in…


Tony

  • Support Staff

August 3, 2017 at 2:28 am

If you go to Event Espresso -> Messages -> Message activity

You should see a list of messages there, what colour status bar (the bar to the left of each row) do they have?


whoon

August 3, 2017 at 2:31 am

Already figured it out, thanks.
Somehow it worked with one smtp plug-in and didnt with the other smtp plug-in..


Tony

  • Support Staff

August 3, 2017 at 2:46 am

Hmm strange.

It could be one of those plugins was adding a header to the email that EE had already added causing it to fail.

Anyway, I’m glad you have it working.

Viewing 21 reply threads

The support post ‘Theme conflict’ 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.

Event Espresso