Helping Visitors Find What They Need Using Custom Searches

   Dario

March 16, 2020

If your site has a lot of information, the best way to let visitors find what they need is with a custom search. Toolset Blocks lets you build custom searches using a drag-and-drop editor. You choose what to search by, design the search box and the search results.

Creating a custom search

See how we create a complete custom search in less than 5 minutes.

When to use a custom search

Any site with a lot of entries benefits from having a good custom search. 

This is especially true for:

  • Directory sites
  • Classifieds sites
  • Real estate sites
  • Travel sites
  • Educational sites
  • E-commerce Sites

Even a blog with a nice (big) archive of articles could use a good custom search. We also use one on our very own Toolset.com blog archive.

How to build quality custom searches

Here are the essential steps for building quality custom searches.

  1. Design a good site structure and organize your content by custom post types and taxonomies. This will make your custom searches easier to use.
  2. Create custom fields to provide important information about your content. Remember, you can use these custom fields as filters in your custom searches.
  3. Use post relationships to connect different post types when needed. This allows you to easily display related data but also create filters based on those relations.
  4. Insert a Toolset View block into a page where you want to list content and provide a custom search. Enable the Search option in the View creation wizard.
  5. Use the View Output section to design how to display custom search results. Use Toolset blocks to display information coming from dynamic sources like custom fields and taxonomies.
  6. Use the View Search section to add search filters. Make the filters as simple as possible for visitors to use. A dropdown menu is much easier to use than a free text field. It’s usually best to provide predefined options to select from.

Feedback? Comments?

Are you building custom searches using Toolset Blocks? How is it going?

Leave us a comment and we’ll be happy to answer!

 

Comments 13 Responses

  1. I’m currently building this exact type of thing and had a question. My CPT has three custom taxonomies that I’m using as my filters. Is there a way to have each filter dropdown update based on what is chosen in the other filter dropdown? For example, one filter is manufacturer and another is product type (carpet, hardwood, tile, etc.). If someone chooses a manufacturer from the select box I would want the product type select box to update to only show valid product options if for example the manufacturer they chose does not produce tile. Does that make sense?

    • Hi, David! Yes, you can!

      To enable this use the following steps:
      1. Select the View Search block and expand the Custom Search section in the right sidebar.
      2. Select the AJAX refresh when changing any filter option.
      3. Turn on the Show only filter options that would produce results option.

      That’s it!

      Here’s a screenshot, so you know exactly what I mean:
      https://www.screencast.com/t/zJBX7pw1zsU

      • Dario-

        Thank you. However, where do I find this in the old Views interface? Either I’m staring right at it or it only exists in the Toolset Blocks version. Appreciate it. I’ll be so happy to get this working as it will essentially complete my project.

        • Hi, David! Sure, here are the steps for the old Views interface:
          1. Edit the View in question and go to the Custom Search Settings section.
          2. There, select the Let me choose individual settings manually option and look in the section Which options to display in the form inputs.
          3. Make sure to select the Show only available options for each input option.

          Here is a screenshot of this:
          https://cdn.toolset.com/wp-content/uploads/2018/01/toolset-views-custom-search-settings-manual-1.png

          • THANK YOU! That’s it, my page is working as I was intending. So glad it was just an easy thing to set and I feel a little embarrassed to have overlooked it. I tried searching the support forums but couldn’t seem to explain my issue well enough to return an appropriate result. Thank you again.

  2. oh, so we no longer need to add the Relevanssi plugin to do searches within custom fields? And can this type of search also created without needing Toolset blocks (just using shortcodes?).

    • Hi, Timothy! Actually, Relevanssi allows you to have a better “free form” search, where you type in what you are looking for. Toolset’s custom search on the other hand allows you to do even better than that because you can provide your visitors with easy-to-use controls to allow them to filter the content. For example, imagine a simple dropdown menu that allows them to select which category of posts they want to see. They select and get only those posts.

      Yes, you can create custom searches also with Toolset Views and its shortcode-based workflow but it’s more complex because you need to deal with HTML markup and styling. If you need more information about that, here is the documentation page for that:
      https://toolset.com/documentation/user-guides/views/front-page-filters/

  3. Thanks for the explanation. So just for clarification, the toolset free form search doesn’t search custom fields?

    • Hi, Timothy! You can search through custom fields via Toolset custom search, but you have to use a separate text field input.

      For example, let’s say you have a custom field for the name of a venue. Into your custom search, you need to insert a text search field that will be “based on” that custom field. In other words, your custom search will then have a text search field that only searches through values of that custom field.

      But you cannot add a text field that will allow searching through post title and content, and also the custom fields.

      For this, you should use Relevanssi, yes. We have a documentation page that explains how to use it with Toolset, here:
      https://toolset.com/documentation/user-guides/views/searching-texts-custom-fields-views-relevanssi/

Leave a Reply  

Please leave here comments about this page only.
For technical support and feature suggestions, head to our forum. We are waiting there!

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>