A section block for Shopify that adds some nice select boxes for filtering collections by tags.
Allows for separating tag groups into separate select boxes for a clean look.
Ajaxify setting so customers can browse without having the page refresh.
Filters are based on Shopifys default filter system which uses tags, examples include price filter, type filter, brand filter, colours, sizes and many more.
Original by Nitin Sharma forked by Harry K (xigetime)
- Simply drop the collection-filters-section.liquid file into your sections directory.
- In your collection.liquid template, add the following to include the section:
{% section 'collection-filters-section' %}
- In your Shopify Admin dashboard, navigate to Themes > Your Theme > Customise > Then open a collection page and you should see the filters section ready to be configured!
- Enable tag filtering: Enables/disables the collection filters from within the admin
- Filter Type: Choose whether you would like to filter by any available tags, or a specific group of tags.
- Groups to use in filter: If groups is selected for filter type, here seperated by a comma you can specifiy each filter group.
- Ajaxify Filters: Turn this on to fetch the new products/pages via Ajax.
- Product container class or id: The products container element selector, everything inside this element will be replaced with the new pages products.
- Pagination container class or id: The paginations container element selector, we need to fetch the pagination, otherwise when they go to the next page they will loose their filters.
Group tags, are product tags and should be formatted like so: Group:Value
Examples: Brand:Nike - Size:L - Vendor:Me - Price:Under 10