Magento: How to call block directly from phtml file without defining in layout?
You can call your block directly from a phtml file with the following code. You can keep this code and call the block from any phtml file. I have assumed my module name as Newmodule and my block name as Newblock.php. The phtml file for the block is assumed to be newmodule/newblock.phtml echo $this->getLayout() ->createBlock('newmodule/newblock') … Read more