WordPress filter hook · part of WordPress core
wp_query_search_exclusion_prefix
A WordPress core filter that 31 plugins also fire themselves, running on 7.5M+ sites between them.
“This filter is documented in wp-includes/class-wp-query.php”
How to use wp_query_search_exclusion_prefix
It's a filter: your callback receives the value, and must return the (changed) value.
Add this to your theme's functions.php or a small custom plugin:
add_filter( 'wp_query_search_exclusion_prefix', function( $value ) {
// Change $value here.
return $value;
}, 10, 1 );Argument names come from WooCommerce's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
This hook is fired by WordPress core too. Official reference on developer.wordpress.org →
31 plugins that fire wp_query_search_exclusion_prefix
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
WooCommerce7+ million installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-wc-query.php:727 -
Unlimited Elements for Elementor300,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', "-" )inc_php/unitecreator_ajax_search.class.php:67 -
WP Job Manager70,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )wp-job-manager-functions.php:543 -
Easy MCP AI40,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/tools/class-base-tool.php:1078 -
ATUM WooCommerce Inventory Management and Stock Tracking10,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )classes/Components/AtumListTables/AtumListTable.php:4360 -
FV Flowplayer Video Player10,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )models/db.php:2164 -
Motors8,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/query.php:548 -
Create5,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )lib/creations/class-creations.php:371 -
Sensei LMS Certificates4,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )classes/class-woothemes-sensei-certificates.php:615 -
Front End PM4,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-fep-message-query.php:335 -
Transliterator3,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )classes/search.php:25 -
SrbTransLatin2,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )lib/Frontend/Search_Query_Transliterator.php:115 -
Falang multilanguage for WordPress2,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )public/class-falang-public.php:2328 -
Phone Orders for WooCommerce1,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )classes/tabs/class-wc-phone-orders-add-order-page.php:2233 -
FV Player 81,000+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )models/db.php:2582 -
Infinite Uploads800+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )inc/InfiniteUploadsAbilities.php:1585 -
Sublanguage600+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )class-current.php:1858 -
Unlimited Elements Blocks Library500+ installs
apply_filters( 'wp_query_search_exclusion_prefix', "-" )inc_php/unitecreator_ajax_search.class.php:67 -
ChinaDS100+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )inc/taobao-post-query.php:184 -
powerSearch for bbPress100+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )core/basic/bbPress.php:197 -
Automatic Multilingual AI Translation by Autoglot100+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )autoglot.php:1573 -
PhotoPress100+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )modules/search/ImageSearch.php:251 -
Persian Kit: Complete Persian/Jalali Pack50+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )src/Modules/CharNormalization/SearchFilter.php:50 -
HANDMADE40+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class/handmade-post-query.php:181 -
Antwork Field Editor: Quick Edit, Bulk Edit & Admin Columns for ACF & SCF10+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-list-query.php:267 -
Post Kinds for IndieWeb in Block Themes10+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-meta-fields.php:2750 -
DMZ B2B Product Management10+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-b2b-products-search.php:73 -
Rooster One10+ installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-aieo-filter-endpoint.php:378 -
SwiftLingFewer than 10 installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/search.php:333 -
MWT Search SteerFewer than 10 installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )src/Search/SearchFilter.php:139 -
YaftinoFewer than 10 installs
apply_filters( 'wp_query_search_exclusion_prefix', '-' )includes/class-query-plan.php:26
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.