1

I have a list of products with 3 attributes (Date, among others) to sort by. By default the sorting is an ascending order, is there a way to change it to be a descending order instead?

2

You cannot change it simply in the backend, however you can edit the local.xml file and add the following depending on your needs

Location of that file is here normally:

app/design/frontend/{package}/{theme}/layout

<layout>
    <catalog_category_default>
      <reference name="product_list_toolbar">
          <action method="setDefaultDirection"><string>asc</string></action>
      </reference>
    </catalog_category_default>

    <catalog_category_layered>
      <reference name="product_list_toolbar">
        <action method="setDefaultDirection"><string>asc</string></action>
      </reference>
    </catalog_category_layered>

    <catalogsearch_result_index>
      <reference name="search_result_list">
        <action method="setDefaultDirection"><string>asc</string></action>
      </reference>
    </catalogsearch_result_index>
    <catalogsearch_advanced_result>
      <reference name="search_result_list">
        <action method="setDefaultDirection"><string>asc</string></action>
        </reference>
    </catalogsearch_advanced_result>
</layout>
  • updated the answer – Klettseb May 18 '16 at 10:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.