Available since: 1.0.6
searchwp_max_search_terms_{$engine}
View Parameters »By default SearchWP considers the same maximum number of search terms for the default engine and all supplemental engines, but if you’d like to modify the maximum number of accepted search terms for a specific supplemental search engine, add something like the following to your theme’s functions.php
:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function my_searchwp_max_search_terms_my_engine( $num_terms) { | |
return 10; // allow 10 search terms for 'My Engine' | |
} | |
add_filter( 'searchwp_max_search_terms_my_engine', 'my_searchwp_max_search_terms_my_engine' ); |
Parameters
Parameter | Type | Description |
---|---|---|
$num_terms |
Integer |
The number of terms to accept for a single supplemental engine |