I'm trying to build in the ability for customers to sort product/collection pages by product SKU numbers. I'm not sure if this is something that can be done through Shopify's liquid code, though I thought I'd see if anyone could confirm that or knew of a possible alternate solution.
The sorting options are a common feature in Shopify and appear in most themes like this:
The sorting code:
<select name="sortBy" id="sortBy">
<option value="manual">{{ 'collections.sorting.featured' | t }}</option>
<option value="best-selling">{{ 'collections.sorting.best_selling' | t }}</option>
<option value="title-ascending">{{ 'collections.sorting.az' | t }}</option>
<option value="title-descending">{{ 'collections.sorting.za' | t }}</option>
<option value="price-ascending">{{ 'collections.sorting.price_ascending' | t }}</option>
<option value="price-descending">{{ 'collections.sorting.price_descending' | t }}</option>
<option value="created-descending">{{ 'collections.sorting.date_descending' | t }}</option>
<option value="created-ascending">{{ 'collections.sorting.date_ascending' | t }}</option>
</select>