Support

Home Forums Event Espresso Premium CLosing Date and Time of event

CLosing Date and Time of event

Posted: August 1, 2017 at 7:10 am


k9nosetime

August 1, 2017 at 7:10 am

Hello
just wondering how i can show the closing date and time of an on line event please?
thanks
Sue


Josh

  • Support Staff

August 1, 2017 at 2:26 pm

Hi Sue,

Do you mean the date and time when ticket sales close? If so, that’s something that you can see by clicking on the view details link within the ticket selector. There you will see a section that lists the sale start and end dates.


k9nosetime

August 2, 2017 at 8:30 am

Thanks Josh sorry i wasnt clear in my question…yes date and time when the ticket closes but is there any way to see this just automatically without clicking on the view details link please?
Sue


Josh

  • Support Staff

August 2, 2017 at 8:44 am

Yes there is if you add some custom PHP code. May I ask where on your site do you want to include that information?


k9nosetime

August 2, 2017 at 9:28 am

Hi Josh
please see this link
https://www.k9nosetime.com/upcoming-events/
would like to show the opening and closing dates and times of tickets here if possible please
thanks
Sue


Josh

  • Support Staff

August 4, 2017 at 12:49 pm

Hi Sue,

The page is using the Events Table template shortcode to display the list of events. The template is customizable by adding some html and PHP code to the template. The documentation has some general direction on how to set up a custom template:

https://eventespresso.com/wiki/events-table-view-template-add-on/#customizations

After you’ve copied over the template file you’ll make some edits to your copy.

First edit: You add this to the table header section:

<th class="th-group" data-sort-ignore="true"><?php _e('Sales start/end','event_espresso'); ?></th>

Second edit: You change this:
<td colspan="4">
to be 5
<td colspan="5">

Third edit: You add this to the table rows section:

<td>
<?php
$ticket_start = '';
$ticket_end = '';
$tickets = $post->EE_Event->tickets();
$ticket = reset($tickets);
if ($ticket instanceof EE_Ticket) {
	$ticket_start = $ticket->get_pretty('TKT_start_date');
	$ticket_end = $ticket->get_pretty('TKT_end_date');
	echo $ticket_start . ' / ' . $ticket_end;
}
?>
</td>


k9nosetime

August 5, 2017 at 5:03 am

thanks Josh will give it a go
Sue

The support post ‘CLosing Date and Time of 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.

Support forum for Event Espresso 3 and Event Espresso 4.
Documentation for EE3 and EE4
Documentation for Event Espresso 3

Documentation for Event Espresso 4

Status: closed

Updated by  k9nosetime 2 years, 3 months ago ago

Topic Tags

Notifications

This topic is: resolved
Do NOT follow this link or you will be banned from the site!
[for="input_96_5_3"]
[for="input_96_5_3"]
[gravityform id=96 title=false description=false]
  • This field is for validation purposes and should be left unchanged.
[i]
[i]
[gravityform id=69 title=false description=false]
  • This field is for validation purposes and should be left unchanged.