Tribe__Events__Main::get_series_start_date( int $post_id )
An event can have one or more start dates. This gives the earliest of those.
Contents
Parameters
- $post_id
-
(int) (Required)
Return
(string) The date string for the earliest occurrence of the event
Source
File: src/Tribe/Main.php
public static function get_series_start_date( $post_id ) {
if ( function_exists( 'tribe_get_recurrence_start_dates' ) ) {
$start_dates = tribe_get_recurrence_start_dates( $post_id );
return reset( $start_dates );
} else {
return get_post_meta( $post_id, '_EventStartDate', true );
}
}