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 | |
/* | |
* For the following plugins: | |
* The Events Calendar, Event Tickets, Event Tickets Plus, WooCommerce | |
* | |
* The function hides the quantity form field from the cart page | |
* so users cannot change the product / ticket quantity there. | |
* It shows the number as plain text. | |
* Note: it only allows you to put 1 of all products in the cart!!! | |
* Useful if you are collecting attendee information with Event Tickets Plus |
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 | |
/** | |
* Single Event Meta (Additional Fields) Template Override | |
* for showing values of additional fields in separate lines | |
* vs. comma separated list | |
* | |
* Copy this template in your own theme by creating a file at: | |
* [your-theme]/tribe-events/pro/modules/meta/additional-fields.php | |
* | |
* @package TribeEventsCalendarPro |
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 | |
/* | |
* For the following plugins: | |
* The Events Calendar | |
* | |
* With this snippet you will only see today's events in any | |
* calendar view, if there is no date set in the filter bar. | |
* If there are no events, then "There were no results found." | |
* is shown. | |
* Add to your child theme's functions.php file |
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 | |
/** | |
* Add billing company name to CSV export | |
*/ | |
function tribe_csv_export_add_company_column ( $columns ){ | |
return array_merge ( $columns, array('company' => 'Company') ); | |
} | |
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
/* | |
* Template to modify query order when including events in blog post loop | |
* For The Events Calendar | |
* Paste into functions.php | |
*/ | |
add_action( 'pre_get_posts', 'order_by_modified' ); | |
function order_by_modified( $query ) { | |
if ( $query->is_home() && $query->is_main_query() ) { |
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: Event Tickets Meta Hawk | |
* Description: Lets site administrators soar over attendee meta data supplied by attendees then swoop down, hawk-like, to change it. Proof of concept targeting the WooCommerce provider. | |
* Version: 2016-03-21 | |
* Author: Barry Hughes | |
* | |
* Experiment in making attendee meta editable via the attendee screen. | |
* Well worth bearing in mind that: | |
* |
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
.tribe-events-month .tribe-events-calendar thead th:nth-child(6), | |
.tribe-events-month .tribe-events-calendar thead th:nth-child(7), | |
.tribe-events-month .tribe-events-calendar tbody td:nth-child(6), | |
.tribe-events-month .tribe-events-calendar tbody td:nth-child(7) { | |
display: none; | |
} |
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 | |
/* Barry's version */ | |
/* Remove feeds from all pages */ | |
function remove_single_event_feed_links() { | |
if ( ! class_exists( 'Tribe__Events__Main' ) ) { | |
return; | |
} | |
// Add / Uncomment these lines if you only want them removed on the single event pages. |
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 | |
/* | |
* For The Events Calendar and The Events Calendar: EventBrite Tickets | |
* Renders the EventBrite iFrame on single event page when EventBrite event is set to private | |
* Author: Barry Hughes | |
*/ | |
function eb_iframe_show_even_if_private() { | |
$post_id = get_the_ID(); | |
$api = tribe( 'eventbrite.api' ); |
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 | |
$events = tribe_get_events( | |
array( | |
'eventDisplay' => 'list', | |
'posts_per_page' => 3, | |
'tax_query' => array( | |
array( | |
'taxonomy' => 'tribe_events_cat', | |
'field' => 'slug', | |
'terms' => $group_slug, |