Better Search v2.4.0

I’ve released a major update to Better Search, one of the easiest to use plugins to supercharge your WordPress search results. Better Search v2.4.0 brings a new admin interface to view the popular searches, several enhancements to the banning/filtering settings amongst other changes.

As usual, if you have any questions, please raise them in the support forum. Feature requests and bug notifications are always welcome.

Popular searches view in admin

Better Search v2.4.0 setting - Popular searches view
Better Search v2.4.0 setting – Popular searches view

You can now find two new items under the Better Search menu in your WordPress admin area that help you navigate to the popular searches table.

You can sort the three columns as well as view the daily hits over a custom period by playing with the date filter. If you hover over each term, you will see options to view the results or delete the search term.

Improvements to banning words

Better Search v2.4.0 setting - Filter words
Better Search v2.4.0 setting – Filter words

This version includes two extra settings that allow more control over the banned words filter.

You now have the option to only block whole words. Previously, any word that was partially matched would be filtered/replaced from the search result. If that setting was too aggressive for your blog, you now have the option to limit this to only whole words. In this case, you will need to add more words that you would like blocked.

The second setting is a complete blocking of the search results if any of the words are included in the banned list. If you’re in seamless mode, then you will need to customise your theme to check if the plugin has registered an error message and if so display this instead of the not found result. See sample code that the plugin uses.

if ( '' !== $bsearch_error->get_error_message( 'bsearch_banned' ) && bsearch_get_option( 'banned_stop_search' ) ) {
	foreach ( $bsearch_error->get_error_messages() as $error ) {
		$output = $error . '<br/>';
	}
} else {
	$output = __( 'Please type in your search terms. Use descriptive words since this search is intelligent.', 'better-search' );
}
echo $output;

All changes in Better Search v2.4.0

  • Features:
    • New interface in the admin area to view popular searches. You can also delete the search results from this page
    • New setting Number format count under General to turn on/off the number formating of the search count
    • New setting Exclude Categories under Search to exclude posts that belong to certain categories
    • New setting Stop query on banned words filter under Search to stop searching if the search query contains any word from the banned list i.e. “Filter these words” setting. If you have seamless mode off, Better Search will display an error message. With seamless mode on, this will give a Nothing found message. You can customize it by editing your theme
    • New setting Filter whole words only to only filter the full words from the banned list. When activated, partial words will no longer be blocked. You will need to update your banned words list to record more words that you would like filtered
  • Bug fixes:
    • Options with checkboxes that haven’t been saved in the database should display correctly
    • Fixed bsearch_read_options is deprecated message on activation

Download Better Search

Leave a Reply

Your email address will not be published. Required fields are marked *