Add event_id as an option to the template

This commit is contained in:
savvasha
2017-12-10 21:09:51 +02:00
committed by GitHub
parent 1d4580f262
commit e9b1d84c41

View File

@@ -11,6 +11,7 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
$defaults = array(
'id' => null,
'event_id' => null,
'title' => false,
'status' => 'default',
'date' => 'default',
@@ -58,6 +59,8 @@ if ( $date_future != 'default' )
$calendar->future = $date_future;
if ( $date_relative != 'default' )
$calendar->relative = $date_relative;
if ( $event_id )
$calendar->event_id = $event_id;
if ( $league )
$calendar->league = $league;
if ( $season )
@@ -175,4 +178,4 @@ if ( $title )
if ( $id && $show_all_events_link )
echo '<div class="sp-calendar-link sp-view-all-link"><a href="' . get_permalink( $id ) . '">' . __( 'View all events', 'sportspress' ) . '</a></div>';
?>
</div>
</div>