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 | |
/** | |
* Retrieves the next upcoming recurrence for a given post ID | |
* | |
* @param int $event_id The post ID for the event | |
* | |
* @return WP_Post|null The event post object, or null if nothing was found | |
*/ | |
function tribe_get_next_upcoming_recurrence( $event_id ) { |
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 | |
/* Tribe, add price to ticket in CSV export */ | |
function tribe_add_price_to_ticket ( $value, $item, $column ) { | |
if ( 'ticket' != $column ) return $value; | |
$product = wc_get_product ($item['product_id']); | |
return $value . ' - Price: $' . $product->price; | |
} |
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 | |
/* Tribe, allow products to be an option to add ticket to in 'Events > Tickets > Settings' */ | |
/* WARNING: this brought issues to customers in the past, so activate at your own risk */ | |
if ( class_exists('Tribe__Tickets_Plus__Commerce__WooCommerce__Main') ) { | |
remove_filter( 'tribe_tickets_settings_post_types', array( Tribe__Tickets_Plus__Commerce__WooCommerce__Main::get_instance(), 'exclude_product_post_type' ) ); | |
} |
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 | |
/* Tribe, prevent woo tickets email to be sent */ | |
add_filter( 'wootickets-tickets-email-enabled', '__return_false' ); |
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 | |
if ( class_exists('Tribe__Events__Pro__Mini_Calendar') ) { | |
function tribe_fix_minicalendar_hide_from_listing_conflict ( $query ) { | |
if ( has_action( 'pre_get_posts', array( Tribe__Events__Pro__Mini_Calendar::instance(), 'set_count' ) ) ) { | |
$query->query_vars['eventDisplay'] = 'list'; | |
remove_action( 'pre_get_posts', 'tribe_fix_minicalendar_hide_from_listing_conflict'); | |
} |
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 | |
/** | |
* Event Submission Form Ticket Block | |
* Renders the ticket settings in the submission form. | |
* | |
* Override this template in your own theme by creating a file at | |
* [your-theme]/tribe-events/community-tickets/modules/tickets.php | |
* | |
* @version 4.1 | |
* @package Tribe__Events__Community__Tickets__Main |
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 | |
function strip_tribe_tickets_order_link() { | |
if ( ! class_exists( 'Tribe__Tickets__Tickets_View' ) ) { | |
return; | |
} | |
$tickets_view = Tribe__Tickets__Tickets_View::instance(); | |
remove_action( 'tribe_events_single_event_after_the_meta', array( $tickets_view, 'inject_link_template' ), 4 ); | |
remove_filter( 'the_content', array( $tickets_view, 'inject_link_template_the_content' ), 9 ); |
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 | |
/* Tribe, force event, venue & organizer websites to open in a new window */ | |
add_filter( 'tribe_get_event_website_link_target', function () { return '_blank'; } ); | |
add_filter( 'tribe_get_venue_website_link_target', function () { return '_blank'; } ); | |
add_filter( 'tribe_get_organizer_website_link_target', function () { return '_blank'; } ); |
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 | |
/* | |
* The Events Calendar Pro - Hide Mini Calendar Event List Until Calendar Date is Clicked | |
* TEC PRO @3.11.1 | |
*/ | |
add_action( 'wp_footer', 'tribe_hide_mini_calendar_list_until_clicked', 50 ); | |
function tribe_hide_mini_calendar_list_until_clicked() { | |
?> | |
<script> | |
var $ = jQuery.noConflict(); |