App reviews, troubleshooting, and recommendations
Hey everyone,
I am currently working on a store and I was wondering if there's a way to edit the logic of the sorting feature within collection pages? I am familiar with coding but not much with liquid.
I am looking to make the A-Z sorting feature so that titles with numbers will be at the bottom and the letters at the top. I was trying to play around with the liquid code, but I just can't seem to find where the logic for the sorting functions are kept. All I was able to find is where the drop down main to select each of the options is created:
<span class="filter">
<label for="sort-by">{{ 'collections.sorting.title' | t }}:</label>
<select id="sort-by" class="sort-by" data-default-value="{{ collection.sort_by | default: collection.default_sort_by }}">
{% if section.settings.collection_sort_show_featured %}<option value="manual">{{ 'collections.sorting.featured' | t }}</option>{% endif %}
<option value="best-selling">{{ 'collections.sorting.best_selling' | t }}</option>
<option value="price-ascending">{{ 'collections.sorting.price_ascending' | t }}</option>
<option value="price-descending">{{ 'collections.sorting.price_descending' | t }}</option>
<option value="title-ascending">{{ 'collections.sorting.az' | t }}</option>
<option value="title-descending">{{ 'collections.sorting.za' | t }}</option>
<option value="created-ascending">{{ 'collections.sorting.date_ascending' | t }}</option>
<option value="created-descending">{{ 'collections.sorting.date_descending' | t }}</option>
</select>
</span>
I am using the Canopy theme.
Please help!
Thanks,
Rozen
Another thing that I am willing to settle for is ordering my collections based on the vendor name instead of the title of the product. I would there will be something somewhere defining these sorting options
Hi @Rozen01 - there's not a way to edit the sorting logic in the Shopify UI (!). The best way to do what you're looking to do is to either rename the products or use the custom sorting feature within a collection. If you're interested in maximizing sales, you can also look into collection sorting tools like ours.
Hope this helps!
In Canada, payment processors, like those that provide payment processing services t...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025