Skip to content

Instantly share code, notes, and snippets.

@jesseeproductions
Last active July 16, 2019 13:13
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jesseeproductions/5768685acc4cd48cdd81 to your computer and use it in GitHub Desktop.
Save jesseeproductions/5768685acc4cd48cdd81 to your computer and use it in GitHub Desktop.
WooCommerce Tickets - Set Catalog visibility to Catalog/search for all Tickets
/*
* The Events Calendar - WooCommerce Tickets - Set Catalog visibility to Catalog/search for all Tickets
* Alternative Hooks:
* wootickets_after_update_ticket
* wootickets_after_create_ticke
* @version 3.12
*/
add_action( 'wootickets_after_save_ticket', 'tribe_events_woo_change_visibility' );
function tribe_events_woo_change_visibility( $ticket_ID ) {
update_post_meta( $ticket_ID, '_visibility', 'visible' );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment