MountainRiver CMS
Published on MountainRiver CMS (https://www.mountainriver.net)

Home > Filtering on 2 Taxonomies with Search API and Facets

Filtering on 2 Taxonomies with Search API and Facets [1]

This is a technical guide.

Install Required Modules

drush dl search_api search_api_page search_api_solr facetapi_select

drush en -y search_api_views search_api_facetapi search_api search_api_solr facetapi_select

Setup the Taxonomies

For this example we have 2 taxonomies, domain and team role.

Setup the Content Type

Create content, ensuring that there is content tagged against each taxonomy. The search facet block will not appear if there is no relevant content.

Search facet content type setup

Setup the Search Index

Create a search index.

Ensure that the fields to be used in the view are indexed.

Select fields to index. These are exposed to the view.

Setup the Facets

Enable the facets and configure the display.

Enable the facet

Configure the display. The client for this website wants a select list. This depends on the facetapi_select module.

Set the facet display type to select field.

Index the content

The content now needs to be indexed or reindexed.

Setup the View

Choose the search index as the data source.

Choose the search content for views.

Configure Blocks

Enable blocks so that they are presented. The blocks will only be displayed if there is relevant content to filter on and only on the related views page.

Enable blocks.

View the Page and Block Created

 

 

Taxonomy: 
Technical Guide [2]
  • Products
  • Website Starter
  • Meeting Manager
  • Media Manager
  • Solutions
  • Corporate Website
  • Online Subscriptions, Shops and Paywalls
  • Editing and Solution Guides
  • Government Website
  • Membership Solutions
  • Government Solutions
  • Product Marketing and Campaigns
  • Services
  • Site Security
  • Site Testing
  • Content Review
  • Hosting Services
  • DevOps and System Administration
  • Custom Programming
  • Web Design Services
  • Site Monitoring
  • Copy and Technical Writing
  • About Us
  • Key Personnel
  • Contact
© 2025 MountainRiver
Powered by Drupal

Source URL:https://www.mountainriver.net/technical-guide/filtering-2-taxonomies-search-api-and-facets

Links
[1] https://www.mountainriver.net/technical-guide/filtering-2-taxonomies-search-api-and-facets [2] https://www.mountainriver.net/taxonomy/term/25