Events & Observers

Observer pitfalls of building serious modules in Magento

Observer pitfalls of building serious modules in Magento

Unlike good old WordPress that “every kid in the block” knows how to create a plugin for, Magento is a whole new system. It requires extensive knowledge of OOP, ORM’s, MVC, and few other stuff. This is why not “every kid in the block” can write a module for Magento, and this is why I love it. However, unlike WordPress, Drupal and other community driven systems out there who keep in mind backward compatibility things with Magento things are a bit different.

Read more

Extending Order object and hooking on event in Magento

Extending Order object and hooking on event in Magento

One of my previous articles was a Magento Event Hooks. This one will be a practical example on using the event hooks. Although the more proper way would be to call them Observers, bare with me. I’m use to this “hooks”.

Here’s the walk-trough on how to add a new property (attribute) to an object (Mage_Sales_Model_Order object in our case).

Read more