Skip to content

Instantly share code, notes, and snippets.

@alanef
Created January 6, 2023 16:59
Show Gist options
  • Select an option

  • Save alanef/39cbdab8fcb6ac0731839f911adba867 to your computer and use it in GitHub Desktop.

Select an option

Save alanef/39cbdab8fcb6ac0731839f911adba867 to your computer and use it in GitHub Desktop.
Custom filter for display eventbrite
<?php
/**
* Plugin Name: Display Eventbrite custom code filter
*/
add_filter( 'wfea_api_results', function ( $events, $query ) {
$events = array_filter( $events, function ( $event ) {
return ( isset( $event->post_title ) ) ? preg_match( '#More Than One Story#', $event->post_title ) : false;
} );
return $events;
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment