Hello, I would like to delete some "Sort By" options.

Highlighted
Tourist
23 0 2

I want to get rid of the alphabetical options and the date options but can't find the code to do so. Can anyone help me out.

Thank you in advance!

Using Minimal theme, URL spacecasesofficial.com

image843 (1).png

0 Likes
Highlighted
Shopify Expert
420 42 46

Hello There, 

 

Go to Snippet->collection-sorting.liquid and fine below code:

Comment this code

{% for option in collection.sort_options %}
<option value="{{ option.value }}"{% if sort_by == option.value %} selected="selected"{% endif %}>{{ option.name }}</option>
{% endfor %}


Now you can remove this and add this custom box and change whatever you want but try not to change the value of option

<select name="sort_by" id="SortBy" class="btn--tertiary" aria-describedby="a11y-refresh-page-message">
<option value="manual">Featured</option>
<option value="best-selling">Best selling</option>
<!-- <option value="title-ascending">Alphabetically, A-Z</option> -->
<!-- <option value="title-descending">Alphabetically, Z-A</option> -->
<option value="price-ascending">Price, low to high</option>
<option value="price-descending">Price, high to low</option>
<!-- <option value="created-ascending">Date, old to new</option> -->
<!-- <option value="created-descending">Date, new to old</option> -->
</select>

Want to modify or develop new app, Hire us.
If helpful then please Like and Accept Solution .
Email: support@zestard.com
Shopify Apps URL :- https://apps.shopify.com/partners/zestard-technologies
Custom Modifications Into Shopify Theme | Shopify Private App | SEO & Digital Marketing
0 Likes