Viewing 3 replies - 1 through 3 (of 3 total)
  • Hey NiallN91,

    Thanks for reaching out!

    You can have your events excluded from your site’s search by filtering the arguments for the “tribe_events” post type using the “tribe_events_register_event_type_args” filter and adding “exclude_from_search’ => true” to the arguments.

    This should prevent the events from showing up in your search results.

    Thanks!

    Here is the code I ended up with, to help someone who might stumble here:

    function hide_post_type_from_search( $args ) {
    $args[‘exclude_from_search’] = true;
    return $args;
    }
    add_filter( ‘tribe_events_register_event_type_args’, ‘hide_post_type_from_search’, 20 );
    add_filter( ‘tribe_events_register_venue_type_args’, ‘hide_post_type_from_search’, 20 );
    add_filter( ‘tribe_events_register_organizer_type_args’, ‘hide_post_type_from_search’, 20 );

    Barry

    (@barryhughes-1)

    Thanks for sharing!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Hiding events from website search’ is closed to new replies.