Support

Home Forums Event Espresso Premium Hiding Ticket Selector and Dates and Times on Single Event Page

Hiding Ticket Selector and Dates and Times on Single Event Page

Posted: September 25, 2024 at 3:02 pm

Viewing 9 reply threads


JacqK

September 25, 2024 at 3:02 pm

Hello

Hoping you can provide some CSS to hide the ticket selector and dates and times on the single event page (we put relevant details and ticket selector in the single event page description, so don’t need it appearing again on that page).

We have the EE 5.0.27.p.

Regards, Joe


Garth

  • Support Staff

September 25, 2024 at 3:38 pm

Here is a document to help you figure that out: https://support.eventespresso.com/article/455-how-to-hide-certain-elements-on-event-espresso-pages-using-css

hide the ticket selector and dates and times on the single event page

You want to hide the ticket selector?

Here is a suggestion for the datetimes:

#content > div.post-46842.espresso_events.type-espresso_events.status-publish.hentry.espresso_event_type-single-event.entry > div.entry-content > div > div.event-datetimes {display:none;}


Tony

  • Support Staff

September 25, 2024 at 4:53 pm

I’m a little confused by this.

Hide the ticket selector with CSS? Would you not just disable it on the event?

Hiding the datetimes is simple enough, but I think we need some additional context for this as I don’t want just hide a bunch of data on your using CSS if there is a better option to do it.

Can you post a link to the event and add some more details on what your looking for?


JacqK

September 25, 2024 at 5:19 pm

This reply has been marked as private.


Tony

  • Support Staff

September 26, 2024 at 5:11 am

Ok, so now it makes sense 🙂

To do what you are requesting here you can use this CSS:


.single-espresso_events .event-tickets,
.single-espresso_events .event-datetimes {
    display: none;
}

And done….

But… (there’s always a but!) if you are taking over the output and using the [ESPRESSO_TICKET_SELECTOR] shortcode to determine where that’s then placed you could just tell EVent Espresso not to inject the Ticket Selector and/or Datetimes into the single event view at all (the shortcode will still output the ticket selector) rather than hiding them after the fact.

Something like this snippet:

https://gist.github.com/Pebblo/79429c843eef0dd34da899e295b0755d#file-tw_ee_remove_ticket_selector_and_datetimes_from_single-php

Add that to a custom functions pluign, we have some documentation on doing so here:

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

You can add that to an existing plugin if you already have one.

Note the downside to the above solutions is that if you forget to add a ticket selector shortcode to your events (or have other events you are NOT doing this with) the TS and Datetimes will still be removed.


JacqK

September 26, 2024 at 4:45 pm

This reply has been marked as private.


Tony

  • Support Staff

September 27, 2024 at 4:35 am

This reply has been marked as private.


JacqK

September 29, 2024 at 5:37 pm

This reply has been marked as private.


JacqK

September 29, 2024 at 5:38 pm

This reply has been marked as private.


Tony

  • Support Staff

September 30, 2024 at 7:30 am

Yes, that’s failing because of an issue with the emails and it looks like they are set to send on the same request as the users.

Go to Event Espresso -> Messages -> Settings.

Set the ‘Generate and send all messages:’ option to ‘On a separate request’ and save.

Now test a registration, does it work then?

Note – the above isn’t going to fix anything related to email issues, it just tells EE to generate and send the email on a different request than the user request, so issues with emails don’t cause registrations to stop with an error.

Viewing 9 reply threads

You must be logged in to reply to this support post. Sign In or Register for an Account

Event Espresso