I have added the following code in controller page, but still the nav-bar is not hiding..
$this->loadLayout();
$this->getLayout()->unsetBlock('header');
$this->getLayout()->unsetBlock('footer');
$block = $this->getLayout()->createBlock(
'Mage_Core_Block_Template',
'my_block_name_here',
array('template' => 'ddevs/example_core_block.phtml')
);
$this->getLayout()->getBlock('content')->append($block);
$this->renderLayout();
Best Answer
Better use layout xml for this case. If you want remove menu than you can only set blank template for menu block. If you will remove
menu
block than you will get fatal errorSo try use code below and create
page/blank.phtml
file (of course you can rename this file like you want).