I've created a custom extension and I'm trying to render a custom block. However, I see nothing.
My code is as follows;
app/code/local/Gdaze/Megamenu/etc/config.xml
<?xml version="1.0"?>
<config>
<modules>
<Gdaze_Megamenu>
<version>0.1.0</version>
</Gdaze_Megamenu>
</modules>
<global>
<blocks>
<megamenu>
<class>Gdaze_Megamenu_Block</class>
</megamenu>
</blocks>
</global>
</config>
app/code/local/Gdaze/Megamenu/Block/Customblock.php
<?php
class Gdaze_Megamenu_Block_Customblock extends Mage_Core_Block_Template
{
}
?>
app/design/frontend/rwd/site/gdaze/megamenu.phtml
<?php echo "Works"; ?>
My method of calling the block.
<?php $this->getLayout()->createBlock('megamenu/customblock')->setTemplate('gdaze/megamenu.phtml')->toHtml(); ?>
I don't really understand what's happening here. I've tried whitelisting the block (a new problem since 1.9.2.2) by adding megamenu/customblock. I've googled the cr*p out of this, but everything suggested just doesn't seem to work. Am I missing something really obvious? Any ideas?