• Blog

    Latest from our Blog

  • Tools

    Our Favourite WP Tools

  • Hosting

    Recommended Web Hosts

  • Coupons

    Get great money off deals

  • Themes

    WordPress Theme Directory

  • Plugins

    WordPress Plugins Directory

  • Promote

    Your WordPress Product

It was pointed out to me yesterday that WPLift doesnt have a search box and also that WordPress search is not the most reliable so this set me on a mission to find a solution. I constructed a search reults page and added a search box to the sidebar which is now functional. I tried out a few plugins and the one seemed to do what I wanted and is actively being updated and supported is called “Relevanssi” which is a free plugin which also offers a commercial one with more features. Some of the key features of Relevanssi are as follows :

  • Search results sorted in the order of relevance, not by date.
  • Fuzzy matching: match partial words, if complete words don’t match.
  • Find documents matching either just one search term (OR query) or require all words to appear (AND query).
  • Search for phrases with quotes, for example “search phrase”.
  • Create custom excerpts that show where the hit was made, with the search terms highlighted.
  • Highlight search terms in the documents when user clicks through search results.
  • Search comments, tags, categories and custom fields.

In this tutorial I will show you how to install and configure the plugin …

Install The Plugin

Download the plugin and then in your WordPress admin, visit “Plugins” > “Add New” > “Upload” and upload the file.

Once you have activated the plugin, you will see a new menu option under “Settings” called “Relevanssi” – click that and you can start configuring the plugin.

Build The Index

The first stage of setting up the plugin is to build the index for the first time, so go ahead and press the “Build the Index” button and the plugin will notify you when its done.

Basic Options

After building the index you can set some basic options for how search works – you can give different weights to the post title, tags and comments. You can set an operator of whether any of the search terms are present or if it requires all of them to be present. You can also choose whether to display newest posts at the top of the search results or the most relevent.

Logs

The next section allows you to keep a log of what people have been searching for and to exclude users from this log. I chose to keep a log – Im a stats junkie anyway but this will be interesting to see what people are searching for and could give me post ideas for the future.

Exclusions and Restrictions

Next up we have exclusions and restrictions, this allows you to limit the searching to specific categories and exclude categories and tags from the search results.

Custom Excerpts / Snippets

This section is where you can choose how many characters to include in your excerpt for the search results page. You can also show a number of hits for that search term next to in the results.

Search Hit Highlighting

This is where you can choose how to highlight the search terms in the results page, you can wrap <strong> tags around the result, change the font color or choose a background color.

Indexing Options

The final part of the config screen is many options for how the plugin indexes your content – you can choose to include custom post types if you have them, include tags, shortcodes, comments, You can specifiy stop words – it also lists your 25 most common words from the database and allows you to add those as stop words also.

Conclusion

This seems like a good well-made plugin, I like the fact it keeps a log of searches on your site and the fact you can make it work with custom post-types is a big bonus. After trying a few searches on WPLift it seems to be a big improvement over the default search, so if search is important on your WordPress-based site, give it a go.


Post Tags

Author:

Oliver Dale is the founder of Kooc Media, a small internet company based in the UK. Kooc Media runs several high-profile websites including WPLift, ThemeFurnace and DesignersTalk.

Leave Yours +

11 Comments

  1. I’ve used Relevanssi on a real-estate site I built. I also used Taxonomy Picker - http://www.squidoo.com/taxonomy-picker-wordpress-plugin which allows you to search by custom taxonomies (e.g. price/number of bedrooms/etc. in my example).

    What I’d really like to find one day is a plugin/method, that would convert a search string into a query, so your results could be plotted on a map using the Geotag plugin – http://bobsp.de/weblog/geotag/

    Maybe Geotagging might be a future topic you could cover?

  2. I’ve used Relevanssi on a real-estate site I built. I also used Taxonomy Picker - http://www.squidoo.com/taxonomy-picker-wordpress-plugin which allows you to search by custom taxonomies (e.g. price/number of bedrooms/etc. in my example).

    What I’d really like to find one day is a plugin/method, that would convert a search string into a query, so your results could be plotted on a map using the Geotag plugin – http://bobsp.de/weblog/geotag/

    Maybe Geotagging might be a future topic you could cover?

  3. Basic WordPress search lists results according to date. Recent posts come first and older ones follow. So if the best result is an older post,it will be buried under more recent entries. Moreover, it can’t search comments, categories, tags, shortcode content or excerpts. Well, it sucks.

    Relevanssi seems to be an excellent plugin that will help solve most of your gripes with the standard WordPress search function. The out-of-the-box setup looks pretty decent. Maybe we’ll try it over at http://colorlabsproject.com

    Anyway, great review, Oliver! :D

  4. Raj

    Thanks a ton.. it is extremely useful plugin and helps me in using the search options with in my blog with much more flexibility..

  5. Roman

    what about search on cyrillic documents? is it possible with this plugin?

  6. thanks alot dude. Really helped me out.

  7. niels

    Thank you SO much!!

  8. Eddy

    Great plugin, fixed 3 problems that gave me a headache!

Leave a Reply

* Required Fields.
Your email will not be published.

Search

Our Sponsors