Created
February 3, 2015 19:51
-
-
Save zackkatz/145b23adf02474bbeb2f to your computer and use it in GitHub Desktop.
Force searches to match all parameters, not any.
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 | |
/** | |
* Force searches to match all parameters, not any. | |
* | |
* @link http://docs.gravityview.co/article/55-how-do-i-modify-the-search-mode | |
* @param string $mode 'any' or 'all' | |
*/ | |
function gv_my_modify_search_mode ( $mode ) { | |
return 'all'; // by default is 'any' | |
} | |
add_filter( 'gravityview/search/mode', 'gv_my_modify_search_mode', 10, 1 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Available in plugin form here