wp_search_stopwords
This is a WordPress - wp_search_stopwords hook. The plugin just uses it.
Filters stopwords used when parsing search terms.
Usage
add_filter( 'wp_search_stopwords', 'wp_kama_search_stopwords_filter' );
/**
* Function for `wp_search_stopwords` filter-hook.
*
* @param string[] $stopwords Array of stopwords.
*
* @return string[]
*/
function wp_kama_search_stopwords_filter( $stopwords ){
// filter...
return $stopwords;
}
- $stopwords(string[])
- Array of stopwords.
Where the hook is called
wp_search_stopwords
woocommerce/includes/data-stores/class-wc-data-store-wp.php 568
return apply_filters( 'wp_search_stopwords', $stopwords );