1
votes

I developed a Magento extension which implements several functionalities. Almost all of them work perfectly in versions from 1.4 to 1.7, except for one. That one is an extra form, which is nice to have, but not vital for the rest of the module to work.
To open that form, a menu entry is added to the Admin menu. In versions 1.5 and 1.4, opening such window results in an error message, due to the lack of some classes introduced in version 1.6.

I'm therefore wondering if it would be possible not to add the menu entry to the Admin menu if Magento version is < 1.6. Is there a way to accomplish this?

Thanks in advance for the answers.

1

1 Answers

0
votes

I didn't find any nice event to achieve this.

You can try to observe adminhtml_init_system_config and check wether the menu is in the $config. If it is, you can add or delete things.

Alternative is to rewrite Mage_Adminhtml_Block_Page_Menu or Mage_Adminhtml_Model_Config

But rewriting is a bit overkill if you ask me.