Support

Home Forums Event Espresso Premium How to make small template customization

How to make small template customization

Posted: July 7, 2015 at 10:36 am


Emil

July 7, 2015 at 10:36 am

Hi,
Is there a way to edit the template of the Event page? This is the general question, but until now I stunbled upon a few specific things I would like to change, listed below:
How can I disable this notification from the Event page: “Please note that a maximum number of 10 tickets can be purchased for this event per order.”?
How can I not show the total tickets sold/left (“This Ticket Sold”, “This Ticket Left” , “Total Tickets Sold”, “Total Spaces Left”) on the “Show detail” part of the Event page?
Thank you.
Best Regards,
Emil


Lorenzo Orlando Caum

  • Support Staff

July 7, 2015 at 11:46 am

Hi Emil, there is a template setting available in WP-admin –> Event Espresso –> Events –> Templates –> Ticket Selector.

It can be used to turn off the ticket details.

For the other messaging, are you wanting to change it or hide it completely?

Here is an example of how it can be changed:

https://gist.github.com/lorenzocaum/38baf9ceb1188185187d

If you would like to remove it completely, then you can set the option within the gettext function that appears after the arrow to empty like this:

‘Please note that a maximum number of %1$d tickets can be purchased for this event per order.’ => ”,

The gettext function itself can be added to your child theme’s functions.php file or a site specific plugin.


Lorenzo


Emil

July 15, 2015 at 8:54 am

Hi,
Actually I would like to know how to get rid of some things in the Event page template and maybe move other things around a little.
Can you tell me how to:
– not show the total tickets sold/left (“This Ticket Sold”, “This Ticket Left” , “Total Tickets Sold”, “Total Spaces Left”) on the “Show detail” part of the Event page?
– move the Event description above the Tickets table?
Thanks,
Emil


Lorenzo Orlando Caum

  • Support Staff

July 15, 2015 at 11:59 am

Hi Emil, the ticket selector has template options that can be used to remove those details.

Go to WP-admin –> Event Espresso –> Events –> Templates –> Ticket Selector.

There are a couple options here. You can set it to hide only the ticket count content or have it hide the details link which will also hide the ticket count. Be sure to save changes after updating the settings.

If you are not seeing these options, then please update to the current version of Event Espresso 4:

https://eventespresso.com/wiki/ee4-changelog/

Try this sample coding for adjusting the order of the elements on the event page:

https://gist.github.com/lorenzocaum/a33405557a2a065779ea

It can be added to your child theme’s functions.php file (do not include the opening php tag) or a site specific plugin:

https://eventespresso.com/wiki/create-site-specific-plugin-wordpress-site/

Thanks


Lorenzo


Emil

July 16, 2015 at 8:49 am

Hi Lorenzo,
Thank you, that helped. The ticket count is now removed. As for the template changes, I looked on the resources you’ve sent me and I think I have what I need to achieve what I want.
Thanks.
Emil


Emil

July 16, 2015 at 9:43 am

Hi Lorenzo,
I created a site plugin, added your snippet of code and I’ve got ALMOST the order of items you specified I should get.
You said the snippet will output this order on the Event Page:
event image, event description, ticket selector, datetime
What I’ve got is:
event image, event phone/email, instructor, event description, ticket selector, datetime, venue
Would you be so kind to give me two snippets of code, which will output the following elements in the order specified below? It would be highly appreciated.
1. event image, event description, ticket selector, datetime, event phone/email, instructor, venue
2. event image, event description, ticket selector, event phone/email, datetime, instructor, venue

Or, if you can explain a little more the other version you explained, the one which involves creating a template file, that may make things easier.
For example, in the template file exapmple you’ve given, if I want to change the order of items is it enough to chahge the order of the lines inside the <div class=”espresso-event-wrapper-dv”>, and that will change the order of elements?
If that’s correct, in that template I only see espresso_events-venues, espresso_events-tickets, espresso_events-datetimes, espresso_events-details which let’s say I can move around. Where are the instructor and phone&email?

I’m sorry if my questions are too basic/silly.

Thank you.

Emil


Lorenzo Orlando Caum

  • Support Staff

July 16, 2015 at 1:37 pm

Hi Emil, please go ahead and reverse the proposed changes. Your theme may already have customized templates since event phone and email do not appear in that order by default.

Could you provide a link to any event page on your site?

Thanks


Lorenzo


Emil

July 17, 2015 at 1:59 am

Hi Lorenzo,

I reversed the changes, and here you can see how an event looks like by default in my theme: http://www.hooponoponoromania.ro/events/i-dentitatea-sinelui-prin-hooponopono-seminar-de-baza-i/
Do you think the theme settings interfere with EE4 template settings in some way?
Thanks,
Emil


Lorenzo Orlando Caum

  • Support Staff

July 17, 2015 at 10:50 am

Hi Emil, this isn’t a theme that I recognize and that information can likely be changed with the templates. Could you provide us with a zipped version of the theme here?

support [at] eventespresso.com


Lorenzo


Lorenzo Orlando Caum

  • Support Staff

November 18, 2015 at 8:51 am

Hello again Emil,

As of Event Espresso 4.8.21, there is a custom display re-order option available in the WordPress dashboard.

Backup your WordPress and update your software

https://eventespresso.com/wiki/how-to-back-up-your-site/

You can see the change log for Event Espresso 4 here:

https://eventespresso.com/wiki/ee4-changelog/

Remove existing filters for adjusting the order

If you have used some of the suggested filters to adjust the order of your event elements, then you’ll want to first remove those from your website and they may have been added to your child theme’s functions.php file or a site specific plugin.

Set a custom order through the Templates screen

Afterwards, go to your WP dashboard (WP-admin) –> Event Espresso –> Events –> Templates. The Use Custom Display Order options in the Templates screen can be used to reorder the events elements on the single event page as well as the events listing page.

Again, be sure that any of the filters for adjusting the order have been removed from your site specific plugin or your child theme’s functions.php file before turning on the template reorder option. Otherwise, you may see duplicate content.

Thanks


Lorenzo

The support post ‘How to make small template customization’ 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