Created
September 22, 2021 22:45
-
-
Save lelandf/3c3c16fe94b8046af7be3522e052b889 to your computer and use it in GitHub Desktop.
[TEC] override single event title template part to include start date
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Single Event Title Template Part | |
* | |
* Override this template in your own theme by creating a file at: | |
* [your-theme]/tribe/events/single-event/title.php | |
* | |
* See more documentation about our Blocks Editor templating system. | |
* | |
* @link http://evnt.is/1aiy | |
* | |
* @version 4.7.2 | |
* | |
*/ | |
?> | |
<?php | |
$start_date = tribe_get_start_date( null, false, 'F j, Y' ); | |
the_title( '<h1 class="tribe-events-single-event-title"><span class="tribe-events-single-event-title__date">' . esc_html( $start_date ) . '</span>: ', '</h1>' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment