Created
February 5, 2019 18:42
-
-
Save joshfeck/1d0c78e541b4e24fd744b8805499bb6e to your computer and use it in GitHub Desktop.
Show upcoming dates in EE4 calendar even if they no longer have tickets on sale
This file contains 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 | |
//* Please do NOT include the opening php tag, except of course if you're starting with a blank file | |
add_filter( | |
'FHEE__EED_Espresso_Calendar__get_calendar_events__query_params', | |
'my_ee_remove_ticket_sale_calendar_check', | |
10, | |
7 | |
); | |
function my_ee_remove_ticket_sale_calendar_check( | |
$query_params, | |
$category_id_or_slug, | |
$venue_id_or_slug, | |
$public_event_stati, | |
$start_date, | |
$end_date, | |
$show_expired | |
) { | |
if ($show_expired == 'false' || $show_expired == false) { | |
unset($query_params[0]['Ticket.TKT_end_date']); | |
} | |
return $query_params; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment