0

I made the following changes to my menu.php file.

/app/code/local/Magiccart/Magicmenu/Block/Menu.php

public function getCatTop()
{
    $collection = Mage::getModel('magicmenu/category')->getCollection()
                      ->addAttributeToSelect(array('entity_id','name','magic_label','short_desc','url_path','magic_thumbnail'))
                      ->addAttributeToFilter('parent_id', Mage::app()->getStore()->getRootCategoryId())
                      ->addAttributeToFilter('include_in_menu', 1)
                      ->addIsActiveFilter()
                      ->addLevelFilter(2)
                      ->addOrderField('name');

    return $collection;
}

All of the categories are sorted in alphabetical order. However, I need one specific category to always show up first.

Please help me out.

New contributor
Apurba Nath is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

Your Answer

Apurba Nath is a new contributor. Be nice, and check out our Code of Conduct.

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.