magento display attribute in dropdown

magento display attribute in dropdown

Create a attribute
and then
edit app/code/core/Mage/Catalog/Block/Navigation.php

public function getAllManu()
 {
 $product = Mage::getModel('catalog/product');
 $attributes = Mage::getResourceModel('eav/entity_attribute_collection')
 ->setEntityTypeFilter($product->getResource()->getTypeId())
 ->addFieldToFilter('attribute_code', 'manufacturer'); //can be changed to any attribute
 $attribute = $attributes->getFirstItem()->setEntity($product->getResource());
 $manufacturers = $attribute->getSource()->getAllOptions(false);
 return $manufacturers;
 }

and then
edit app/design/frontend/default/default/template/catalog/navigation/top.phtml


    

You may also like...

Creating a Shopify App using Laravel How to Create Custom WordPress Plugin? How to Build a Telegram Bot using PHP How to Convert Magento 2 into PWA?