Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Community Events: Disable the "Venue Details" linked post type box from the "Add New Event" and "Edit Event" forms.
<?php
/**
* Community Events: Disable the "Venue Details" linked post type box from the "Add New Event" and "Edit Event" forms.
*
* @link https://gist.github.com/cliffordp/2b9369b9c2911fcef05ad10620d954e7 This snippet.
*
* @param array $templates
* @param string $slug
*
* @return array
*/
function cliff_disable_ce_venues( $templates, $slug ) {
if ( 'community/modules/venue' === $slug ) {
return [];
}
return $templates;
}
add_filter( 'tribe_get_template_part_templates', 'cliff_disable_ce_venues', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.