searchwp\query\partial_matches\fuzzy
Since: 4.0.0
Table of Contents
Control whether partial matching logic uses fuzzy matching. By default (when enabled) SearchWP will utilize two levels of partial matching logic.
- Find partial matches that contain the search string
- If no partial matches are found attempt to find tokens that sound like search terms
Parameters
Type | Parameter | Default | Since |
---|---|---|---|
Boolean | $enabled |
true |
4.0.0 |
Examples
All hooks should be added to your custom SearchWP Customizations Plugin.
Disable SearchWP's fuzzy logic when performing partial matches
Disable SearchWP’s fuzzy logic when performing partial matches
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 | |
// Disable SearchWP's fuzzy logic when performing partial matches. | |
add_filter( 'searchwp\query\partial_matches\fuzzy', '__return_false' ); |