I would like to override a specific block of a module that I've downloaded, because there is a specific methods I would like to add, and I don't like the idea of modifying module's core files.
I have hard time to structure my xml correctly, which is why my block does not gets loaded instead of the original one. I've tried following the tips provided by @Joseph in this question, but no luck.
Now, let me provide some file structure.
The interesting part of the downloaded module
<?xml version="1.0"?> <config> <modules> <EM_Megamenupro> <version>1.0.0</version> </EM_Megamenupro> </modules> <blocks> <megamenupro> <class>EM_Megamenupro_Block</class> </megamenupro> </blocks> </config>
The block I am trying to modify is located in
Now, my module is located in
app/local/Acme/Demo, my block is located in
My module is active(I checked it up in Administrative panel, its there)
config.xml file I've added the following nodes, but it does not appear to be working.
<global> <blocks> <megamenupro> <rewrite> <megamenu>Acme_Demo_Block_Megamenu</megamenu> </rewrite> </megamenupro> </blocks> </global>
Any kind of help would be kindly appreciated. Thank you.