3

We are trying to sort the categories in the layered navigation alphabetically but it is not getting sort.

Tried the following modifications directly in core file at line number 122 for testing purpose.

app/code/core/Mage/Catalog/Model/Layer/Filter/Abstract.php
asort($this->_items);

Any help in this regard is highly appreciated.

Thanks in Advance.

0

please check this way ,it may give you the desired result

get all the categories and run the following loop

foreach ($_categories as $_category){ <br>
          $categories[$_category->getName()] = $_category->getUrl();<br>
          ksort($categories, SORT_STRING);<br>
        }

hope it solves your problem.

| improve this answer | |

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.