How to exclude a specific tag from tag filter drop down menu in specific collection page?

There are two collections that have separate pages. I want these collections should not be shown in the filter category drop down menu. also when open two collections then don’t show other tags in filter dropdown

Hi @arksaivi

What’s the theme you are using?

Dawn Theme latest version

You can try go to Online store >Themes > Edit code > open main-collection-product-grid.liquid file, find this line of code


Replace with this code

{% for tag in collection.all_tags %}
  {% unless tag == 'tag 1' or tag=='tag2' %}      
      <option
        value="{{ option.value | escape }}"
        {% if option.value == sort_by %}
          selected="selected"
        {% endif %}
      >
        {{ option.name | escape }}
      </option>
  {% endunless %}
{% endfor %}    

Please replace tag 1, tag 2 in the code with the tags that you don’t want to add and add or tag == “your tags” for each tag

Thank you ! but No working it should be default on collection page no sort _by condition…

Do you mean from the dropdown menu or collection list page?

As given into above screen shot.

As above I want to hide this category from Shop page ( all collection) and

this is single category page where showing category filter option which one I want to hide on this ( Regal thread ) collection page

As shown in screen shot don’t want to show Regal thread into All collection page

Also I want to hide category option on single category page on collection/Regal-threat

please help me out