For some reason, I can't get the getEvent() or getRequest() to work in my observer.
<!--Create an event--> <events> <controller_action_predispatch> <observers> <example_observer> <class>example/observer</class> <method>controllerActionPredispatch</method> </example_observer> </observers> </controller_action_predispatch> </events> And here is the observer:
class MasteringMagento_Example_Model_Observer { public function controllerActionPredispatch($observer){ //die("testing"); //this runs fine $controllerAction = $observer->getEvent()->getControllerAction(); Mage::log($controllerAction->getRequest()->getParams()); } } The die("testing") fires fine, but I can't get the rest of the observer code to work.