Magento – Move static block category

categorymagento-1.9static-block

I want move static block landing in Category. I found code in file

/app/design/frontend/base/default/template/catalog/category/view.phtml

<?php elseif($this->isMixedMode()): ?>
<?php echo $this->getCmsBlockHtml() ?>
<?php echo $this->getProductListHtml() ?>

I tried copy or move <?php echo $this->getCmsBlockHtml() ?> in file 2columns-left.phtml but it does not work.

Best Answer

Add bellow code in file 2columns-left.phtml

<?php if($currentCategory = Mage::registry('current_category')):?>
                <?php echo $this->getLayout()->createBlock('cms/block')->setBlockId($currentCategory->getLandingPage())->toHtml();     
?><?php endif;?>
Related Topic