I have a Magento system with the Shopper theme installed, my client wants me to add a link for the Brand name inside the breadcrumbs title, for example inside the product details page i have a product called 'Kids Toys from Kids Category', the client asks me to make the words 'Kids Category' linkable to the brand name which is 'Kids Category', i already have a plugin for the brands, to do so i added this code inside the ShopByBrand.xml plugin file :

<reference name="breadcrumbs">
   <block type="shopbybrand/productinfo" name="shopbybrand_productinfo" template="shopbybrand/info.phtml"/>

This block will add the brand details for the desired product and it is working fine for other blocks such as alert.urls, but in my case it is not working, could someone help me in that? i need only to have the assigned product brand in the Breadcrumbs section, i know this is little stupid task but this is what the client wants!

1 Answer 1


you can call breadcrumbs like below in your custom block file in your

_prepareLayout function.

if ($breadcrumbs = $this->getLayout()->getBlock('breadcrumbs')) {
    $breadcrumbs->addCrumb('home', array('label'=>$helper->__('Home'), 'title'=>$helper->__('Go to Home Page'), 'link'=>Mage::getBaseUrl()));
    $breadcrumbs->addCrumb('product_list', array('label'=>$helper->__('Brands'), 'title'=>$helper->__('Brands'), 'link'=>Mage::getUrl('brands')));
    $breadcrumbs->addCrumb('product_detail', array('label'=>Mage::getModel('inic_brand/brand')->getBrandName($brand->getBrand(), Mage::app()->getStore()->getId()), 'title'=>$brand->getIdentifier()));

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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