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 | |
add_filter( "woocommerce_get_checkout_url", "rt_fix_maybe_filter_checkout_url_to_attendee_registration", 20); | |
/** | |
* Hooked to the woocommerce_get_checkout_url filter to hijack URL if on cart and there | |
* are attendee registration fields that need to be filled out | |
* | |
* @since 4.9 | |
* | |
* @param string $checkout_url |
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 | |
add_filter( 'woocommerce_email_enabled_wootickets', 'rt_custom_disable_event_ticket_email_by_event', 20, 2 ); | |
/** | |
* @param $enabled | |
* @param $order WC_Order | |
* | |
* @return mixed | |
*/ | |
function rt_custom_disable_event_ticket_email_by_event( $enabled, $order ) { |
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 | |
add_action( 'wp_loaded', 'rt_remove_ticket_email', 80 ); | |
/** | |
* Remove the main filter of ET email and add it again with a check to prevent fatal errors | |
*/ | |
function rt_remove_ticket_email() { | |
if ( ! function_exists( 'tribe' ) ) { |
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 | |
/** | |
* Disable showing Organizer info in Event Details | |
*/ | |
add_filter( 'tribe_has_organizer', '__return_false' ); |
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 | |
/** | |
* Tribe, adding user meta to the attendees csv export | |
* Source: https://theeventscalendar.com/support/forums/topic/adding-woocommerce-order-notes-to-attendees-export/ | |
* | |
* | |
**/ | |
function tribe_export_custom_set_up( $event_id ) { |
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 | |
add_filter( 'tribe_events_ajax_response', 'rt_custom_map_event_title' ); | |
function rt_custom_map_event_title( $data ) { | |
if ( empty( $data['markers'] ) ) { | |
return $data; | |
} | |
foreach ( $data['markers'] as &$marker ) { | |
// Change the following line to modify the markers as needed | |
$marker['title'] = strip_tags($marker['title']); |
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 | |
/** | |
* | |
* Disable Attendee Registration page for WooCommerce in Event Tickets Plus | |
* | |
* @author Rafsun Chowdhury | |
* | |
* @link https://gist.github.com/rafsuntaskin/714d5582bdfe0ed235ef83d36938d8fd | |
* | |
*/ |
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 | |
/** | |
* | |
* Add Custom column with data in Attendee Table | |
* | |
* @author Rafsun Chowdhury | |
* | |
* @link https://gist.github.com/rafsuntaskin/9a138c47068a6d332454ad4605c6244b | |
* | |
*/ |
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 | |
/** | |
* | |
* Set category as required field for CE submission | |
* | |
* @author Rafsun Chowdhury | |
* | |
* @link https://gist.github.com/rafsuntaskin/1b3a4165080629253e34ca87db2027e7/edit | |
* | |
*/ |
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 | |
add_action( 'event_tickets_after_save_ticket', 'rt_disable_tax_for_event_tickets', 10, 4 ); | |
function rt_disable_tax_for_event_tickets( $post_id, $ticket, $raw_data, $class_name ) { | |
//hardcoded for WooCommerce only | |
if ( 'Tribe__Tickets_Plus__Commerce__WooCommerce__Main' != $class_name ) { | |
return; | |
} |