How to Search By Category in WordPress

Categories allow website owners to sort their content while making it easier for their users to browse the site. At pluginthemehub we use different categories to sort content on our site. For example, when a user arrives on our site, they can go directly to the beginners guide section or WordPress tutorials. Doing so they will be able to skip posts in our other categories. Sometimes you may want your users to be able to search inside a specific category rather than the entire site. In the past, we wrote an article about how to create an advanced search form for custom post types, and a lot of you asked if there was a way to do the same thing for categories. In this article we will show you how to add search by category functionality in your WordPress site. The goal is to add a search box that allows visitors to search inside specific categories.

First thing you need to do is install and activate the Category Wise Search plugin. Upon activation, you need to visit Appearance Β» Widgets page. There you will notice a new Category Wise Search widget in the list of available widgets. Simply drag and drop the widget to your sidebar and configure the widget options.

The widget’s settings allow you to exclude categories from the search box. Leaving exclude categories box empty will will show all your categories in the drop down menu. When you are done simply click on the save button to store your widget settings.

You can now visit your website to see the search by category feature in action.

Category Wise Search plugin allows you to exclude categories from your search results, but you can also exclude pages from WordPress search results. Remember that this search by category plugin will only be helpful if you are using categories and tags the right way. We hope this article help you improve your site search by adding search by category feature in WordPress. We are curious to know how many of you still use default WordPress search box on your websites? How many of you are using something advanced like custom post type search, search by category, google custom search, Amazon CloudSearch with Lift, etc? Let us know in your comments below.

Leave a Reply

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

error: Content is protected !!

Pin It on Pinterest

Add address