Magento – How to Check if a Module is Installed and is Active

While developing Magento websites, you might wish to check to find out if a module is installed before proceeding to use that module’s functions. You can do so by using the following bit of code.

/* Returns boolean true or false */
Mage::getConfig()->getModuleConfig('Namespace_Modulename')->is('active', 'true');