Magento 1.7:Show category image on category page in full width in a 2 column template

你离开我真会死。 提交于 2019-12-05 19:56:59

This seems to be a built in feature in Magento.

To enable it do the following:

  • Log in to the admin panel
  • Go to catalog->manage categories
  • Select the category you want to add an image
  • You will see a place where you can add an image (just upload it)
  • Once you add an image it will automatically show in category page

Update

Here is the code to get the category image:

$category = Mage::getModel('catalog/category')->load($catId);
$category->getImageUrl(); // remember to echo it out 

In order to set this up above layered navigation, do the following steps:

  • Add a block to the catalog.xml (in the: <catalog_category_default translate="label"> section.
  • Add the code above to the template file (that you referenced in the block above)

Let us know if you need further assistance with this

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!