The steps below for making changes via custom templates are no longer recommended. You can use this shortcode:
[ESPRESSO_EVENTS_TABLE_TEMPLATE show_all_datetimes=TRUE]
See this page for more information: https://eventespresso.com/wiki/events-table-view-template-add-on/
This can be done by relocating one of the templates and making a change to some lines of code. This will ensure that your customization is not lost on a software update.
The support team at Event Espresso will never recommend you edit any core plugin or add-on files directly.
Here are the steps:
-
Login to your WordPress root with your preferred SFTP or FTP client. Filezilla and Cyberduck are free options. On a Mac? Try Transmit
-
Browse to this location:
/wp-content/plugins/eea-events-table-view-template/templates
You'll see two files there:
espresso-events-table-template-toggle.template.php
espresso-events-table-template.template.php
-
Download a copy of the
espresso-events-table-template.template.php
file to your computer -
Now browse to this location:
/wp-content/uploads/espresso/templates
-
Upload the the file that you downloaded earlier to the location above
-
Open the espresso-events-table-template.template.php file for editing
At about line 99 you'll see this line of code:
$datetimes = EEM_Datetime::instance()->get_datetimes_for_event_ordered_by_start_time( $post->ID, $show_expired, false, 1 );
$datetime = end( $datetimes );
- Replace the line above with this:
$datetimes = EEM_Datetime::instance()->get_datetimes_for_event_ordered_by_start_time( $post->ID, $show_expired, false );
$datetime = end( $datetimes );
- At about line 112 you'll see this line of code:
<td class="start_date event-<?php echo $post->ID; ?>" data-value="<?php echo $datetime->get_raw( 'DTT_EVT_start' ); ?>"><?php echo $startdate; ?></td>
- Replace it with this:
<td class="start_date event-<?php echo $post->ID; ?>" data-value="<?php echo $datetime->get_raw( 'DTT_EVT_start' ); ?>">
<ul>
<?php
foreach ( $datetimes as $datetime ) {
echo '<li style="list-style-type:none;">'.$datetime->start_date_and_time().'</li>';
} ?></ul></td>
Then save changes.
Here is an alternative version that will show all datetimes along with an iCal button for each.
This can be done by relocating one of the templates and making a change to some lines of code. This will ensure that your customization is not lost on a software update. Here are the steps:
Login to your WordPress root with your preferred SFTP or FTP client. Filezilla and Cyberduck are free options. On a Mac? Try Transmit
Browse to this location:
/wp-content/plugins/eea-events-table-view-template/templates
You'll see two files there:
espresso-events-table-template-toggle.template.php
espresso-events-table-template.template.php
Download a copy of those files above to your computer
Now browse to this location:
/wp-content/uploads/espresso/templates
Upload the two files that you downloaded earlier to the location above
Open the espresso-events-table-template.template.php file for editing
At about line 8 add the following code snippet just above the "if ( have_posts() ) :)"
Then save changes.