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 | |
/* | |
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. | |
A long term that starts in the past shows up in the current month rather than appearing in its own month. | |
For example if an exhibition runs for a year from 1 April 2016 – 1 April 2017, it would currently mean | |
that the calendar would have a April 2016 section at the top which just looks like you have out of date info. |
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 | |
/* | |
* In month view the month with the first upcoming event is shown | |
* Author: Barry Hughes, Andras Guseo | |
* Last updated: February 17, 2017 | |
*/ | |
add_action( 'tribe_events_pre_get_posts', 'fast_forward_month_view' ); | |
function fast_forward_month_view( $query ) { | |
// Don't interfere with other month views (like mini-cal) |
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 snippet shows the event title and event start date on the WooCommerce cart page | |
* Done with the help of @Rachel ;) | |
*/ | |
add_filter( 'woocommerce_cart_item_name', 'example_testing', 10, 3 ); | |
function example_testing( $title, $values, $cart_item_key ) { | |
$ticket_meta = get_post_meta( $values['product_id'] ); | |
$event_id = absint( $ticket_meta['_tribe_wooticket_for_event'][0] ); |
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 | |
/* | |
* Changes the formatting of the timepicker in The Events Calendar: Community Events submission form | |
* Change format in line 17 based on https://codex.wordpress.org/Formatting_Date_and_Time | |
* | |
* Author: Barry Hughes | |
*/ | |
function ce_timepicker_24hr_fix() { | |
echo " | |
<script type='text/javascript'> |
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 | |
class Tribe__Events__Filterbar__Filters__Cost_Custom extends Tribe__Events__Filterbar__Filter { | |
const EXPLICITLY_FREE = 'set_to_0'; | |
const IMPLICITLY_FREE = 'unset_or_0'; | |
public $type = 'range'; | |
public $free = self::IMPLICITLY_FREE; | |
private $min_cost = 1; | |
private $max_cost = null; |
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 | |
/* LOAD CUSTOM STYLES AT THE END OF THE PAGE */ | |
function hide_tinymce() { | |
?> | |
<style type="text/css"> | |
#postdivrich { | |
display: none; | |
} | |
</style> |
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 | |
/* | |
* Limit the number of words in the excerpt in photo view | |
* For Events Calendar Pro | |
* Last update: March 13, 2017 | |
* Last version checked: ECPro 4.4.4 | |
* Author: Barry Hughes | |
*/ | |
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
"X-Poedit-Basepath: ..\n" | |
"X-Poedit-SourceCharset: UTF-8\n" | |
"X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;_nx_noop:3c,1,2;__ngettext_noop:1,2\n" | |
"X-Poedit-SearchPath-0: .\n" | |
"X-Poedit-SearchPathExcluded-0: *.js\n" |
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 there are no tickets available for a future event, or the event is in the past, | |
* Then a message will be shown to the users on the single event page. | |
* | |
* For The Events Calendar and Event Tickets plugins by Modern Tribe | |
* Author: Andras Guseo | |
* Last updated: May 1, 2017 | |
*/ | |
add_action( 'tribe_events_single_event_after_the_meta', 'no_tix_message' ); |
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 | |
/** | |
* Adds a + iCal link to each ticket in the tickets email | |
* | |
* @see tribe_tickets_ticket_email_ticket_bottom | |
*/ | |
function tribe_add_ical_to_email( $order ) { | |
// Temporarily change global post. | |
$original_post = $GLOBALS['post']; |