Created
January 10, 2014 15:27
-
-
Save jchristopher/8356348 to your computer and use it in GitHub Desktop.
Tell SearchWP's Term Highlight Extension to skip highlighting terms for searches performed with specific search engines
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_th_excluded_engines( $load_posts, $search_args ) { | |
// DO NOT highlight terms when using the 'my_supplemental' search engine | |
return array( 'my_supplemental' ); | |
} | |
add_filter( 'searchwp_th_excluded_engines', 'my_searchwp_th_excluded_engines', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment