Skip to content

Instantly share code, notes, and snippets.

Brian jesseeproductions

Block or report user

Report or block jesseeproductions

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@jesseeproductions
jesseeproductions / cctor-pro-after-counter-msg.php
Created Jun 3, 2019
Coupon Creator Pro After Counter Message
View cctor-pro-after-counter-msg.php
add_action( 'cctor_click_actions', 'cctor_pro_after_counter_msg', 15, 2 );
function cctor_pro_after_counter_msg( $coupon_id, $coupon_expiration = null ) {
if ( ! is_singular( Cctor__Coupon__Main::POSTTYPE ) ) {
return false;
}
if ( ! is_object( $coupon_expiration ) ) {
return false;
}
@jesseeproductions
jesseeproductions / tribe-woo-bcc.php
Created Mar 26, 2019
Send Bcc Email for WooCommerce Tickets
View tribe-woo-bcc.php
/**
* Function adds a BCC header to emails that match our array
*
* based off snippet from https://jessepearson.net/2016/10/adding-bcc-emails-woocommerce/
*
* @param string $headers The default headers being used
* @param string $object The email type/object that is being processed
*/
function tribe_add_bcc_to_certain_emails( $headers, $object ) {
@jesseeproductions
jesseeproductions / tribe-no-sales-tax.php
Created Mar 13, 2019
Prevent Sales Tax For Tickets under a certain Event or Post ID
View tribe-no-sales-tax.php
/**
* Prevent Sales Tax For Tickets under a certain Event or Post ID
*/
add_filter( 'tribe_tickets_commerce_paypal_add_to_cart_args', 'tribe_add_tax_rate_to_paypal_transaction', 10, 3 );
function tribe_add_tax_rate_to_paypal_transaction( $args, $php_post, $post ) {
// change 15713 to the event or post id with the tickets that should not collect sales tax
if ( $post->ID === 15713 ) {
$args['tax_rate'] = '00.00';
}
@jesseeproductions
jesseeproductions / tribe-ticket-woo-attendee-delay.php
Created Jan 29, 2019
Change Delay of Ticket Creation to Now
View tribe-ticket-woo-attendee-delay.php
/**
* Change Delay of Ticket Creation to Now
*/
add_filter( 'tribe_ticket_generation_delay', 'jp_filter_delay' );
function jp_filter_delay( $timestamp ) {
return date( 'm/d/Y h:i:s a', current_time( 'timestamp' ) );
}
@jesseeproductions
jesseeproductions / couponloop-shortcode-loading.php
Created Nov 2, 2018
Load Loop Shortcode in Header if Found in Content
View couponloop-shortcode-loading.php
/**
* Load Loop Shortcode in Header if Found in Content
* https://wordpress.stackexchange.com/a/207749
*/
add_action( 'wp_enqueue_scripts', 'cctor_load_resources' );
function cctor_load_resources() {
global $post, $wpdb;
// determine whether this page contains "couponloop" shortcode
$shortcode_found = false;
@jesseeproductions
jesseeproductions / mu-loader.php
Created Aug 8, 2018
MU Loader for The Events Calendar and Events Calendar Pro
View mu-loader.php
<?php
/*
Plugin Name: MU Plugin Loader
Description: Loads plugins in mu-plugins subdirectories
*/
include_once 'events-pro/events-calendar-pro.php';
include_once 'the-events-calendar/the-events-calendar.php';
@jesseeproductions
jesseeproductions / tribe-google-map-region
Created Jul 23, 2018
Set Region and Language for Google Maps
View tribe-google-map-region
/**
* The Events Calendar - Set Region and Language for Google Maps
*
* Language Codes https://developers.google.com/maps/faq#languagesupport
* Region codes: https://developers.google.com/maps/documentation/javascript/geocoding#GeocodingRegionCodes
*/
add_filter( 'tribe_events_google_maps_api', 'tribe_add_google_map_region' );
add_filter( 'tribe_events_pro_google_maps_api', 'tribe_add_google_map_region' );
function tribe_add_google_map_region( $api_url ) {
@jesseeproductions
jesseeproductions / cctor-pro-css-header.php
Created Mar 29, 2018
Load Coupon Creator Pro CSS in Header
View cctor-pro-css-header.php
add_action( 'wp_enqueue_scripts', 'cctor_enqueue_assets', 11 );
function cctor_enqueue_assets() {
if ( ! is_admin() ) {
// @formatter:off
wp_enqueue_style(
'coupon_creator_css',
Cctor__Coupon__Pro__Main::instance()->resource_url . 'css/coupon-pro.css',
array( 'pngx-font-awesome' ),
filemtime( Cctor__Coupon__Pro__Main::instance()->resource_path . 'css/coupon-pro.css' )
);
@jesseeproductions
jesseeproductions / list-view-start-tribe.php
Last active Feb 9, 2017
The Events Calendar List View Multi Day Events Show Today as the Start Date
View list-view-start-tribe.php
<?php
/*
Plugin Name: A Snippet for List View Multi Day Events Start Time - The Events Calendar
Plugin URI: http://theeventscalendar.com
Description: This plugin changes the List View Start Times for Multiple Day Events.
Author: brianjessee
Version: 1.0
Author URI: http://theeventscalendar.com
*/
/**
@jesseeproductions
jesseeproductions / tribe-enable-shortcodes-excerpt.pjp
Created Jun 27, 2016
Tribe - Enable Shortcodes in Excerpt of List View
View tribe-enable-shortcodes-excerpt.pjp
/**
* Tribe - Enable Shortcodes in Excerpt of List View
*/
add_filter('tribe_events_excerpt_allow_shortcode', 'tribe_events_excerpt_enable_shortcode' );
function tribe_events_excerpt_enable_shortcode( $args ) {
return true;
}
You can’t perform that action at this time.