How to Create Custom Module in Magento 1.9

Doing the installation, activation, and checking of the module will lead you to completing the process. Try the Event Observer in this process where the extension of Magento’s functionalities without having to rewrite or override any core classes, methods, or functions is possible. As we always satisfy our clients with the necessary Magento support that they need, we would be glad to share with you simple steps in creating a Magento 1.9 custom module that will fit to your specific needs. Creating a Magento 1.9 Custom Module has to be done deliberately.

Deliberate execution has to be done so make sure to disable the Cache by going to the Admin Panel > System > Cache Management > Select All > Actions then perform the Disable > Submit. From here, familiarize yourself with the directories present. We have the app/code directory where the core files and codes of Magento are, the app/code/core that has the functionalities for products, categories, customers, payments, etc. The app/code/community directory, on the other hand, has the third party-provided modules or those not under the Magento’s Core Team. The empty directory app/code/local directory is the area where we will structure our codes.

First step in the structuring process is to create the necessary directories to be used. Go to the app/code/local directory where adding of new files and folders will be done. Create the first directory “namespace” which can be the company, author or developer’s name. Thus, the directory app/code/local/ “namespace”. The next is the creation of a module name directory which will appear like this: app/code/local/Mage/ProductLogUpdate if the module is for product log update.

From here, configure the module according to its requirements inside the module’s directory. In this case, the ProductLogUpdate e.g. app/code/local/Mage/ProductLogUpdate/etc/config.xml. This XML XML will lead Magento to the location of the module and the files inside the module along with other items like the module version, events, models etc.

To activate the module, lead Magento the module that exists which was created by a new XML file in app/etc/modules/ “namespace”_ProductLogUpdate.xml. Code the <active> as to whether true (active) or false (inactive) and the <codePool> as to whether core, community or local. Now that the module is enabled in Magento, check them out by logging into the Magento Admin Panel and browse through System > Configuration > Advanced > Advanced and view the Disable Module Output listing. You should expect to have your “namespace”_ProductLogUpdate module present there. Otherwise, redo the process and figure out where you committed any mistake in the process.

Aren’t those easy? If you find it difficult or further needs our assistance, you know where you can contact us for help.

About our Company:

Sparx BPO, A professional Magento development services provider agency. We offer total magento 2 ecommerce solutions including Magento 2 Theme Development, Magento 2.2 upgrade Services, Magento 2 Website Development, Magento 2 Enterprise Development and Magento 2 Mobile App Development

Posted on:
Post author

Leave a comment

Your email address will not be published. Required fields are marked *