Version:

    Filter element

    Use the Filter element to add Exposed filters to your View template. The settings for the exposed filters are configured within the Drupal views user interface.

    Using the Filter element you are able to render an exposed filter in the format Drupal provides or as a list. If you want to style the exposed filter using Site Studio you must use the List style display. You cannot style exposed filters which are set to display as a Select (drop-down).

    Locating the filter element

    To find the Filter element:

    1. Navigate to a page or template with the Layout canvas
    2. Click the + button on the Layout canvas
    3. Within the Elements tab, look for the Filter element.

    filter.png

    The Filter element includes the following fields:

    View filter

    The following fields are dependant on the filters set-up within your view.

    • View - Select the View the template will be used for
    • View display - Select the View display. For all displays, select Master. View displays are set-up within Drupal views
    • Exposed filters - Select the exposed filter to use. Exposed filters are set-up within Drupal views
    • Filter display type - Select how the filter should be displayed.
      • Drupal default - This will use display Drupal provides. The style of this display needs to be defined in your Drupal theme by a developer
      • List style - Use a Site Studio Custom list style. This can be used to style filters that are lists. For example, lists of tags, categories or authors. The list style cannot be applied to filters set to display as a Select (drop-down)
    • List stye - If List style is selected within Filter display type, you can select the specific List custom style to use.

    View reloads on change

    • Reloads on change - Set the filter to reload the view when the user clicks on a filter option. If using the Filter submit button element then toggle this setting to off.

    Comments

    DX8 knowledge base icon

    Frequently asked questions

    Get instant answers to common questions. Available online 24/7.

    Find answers

    Raise a ticket icon

    Raise a support ticket

    To raise a ticket, sign into Acquia Cloud and select Help in the top menu.

    Raise support ticket

    Acquia

    Copyright © 2020 Acquia, Inc. All Rights Reserved. Drupal is a registered trademark of Dries Buytaert.