Skip to content

Instantly share code, notes, and snippets.

@nhp
Created April 8, 2013 10:44
Show Gist options
  • Save nhp/5335880 to your computer and use it in GitHub Desktop.
Save nhp/5335880 to your computer and use it in GitHub Desktop.
<?xml version="1.0"?>
<config>
<modules>
<Spl_Navigation>
<version>0.0.1</version>
</Spl_Navigation>
</modules>
<global>
</global>
<frontend>
<events>
<page_block_html_topmenu_gethtml_before>
<observers>
<navigation_page_block_html_topmenu_gethtml_before>
<type>singleton</type>
<class>spl_navigation/observer</class>
<method>topmenuGethtmlBefore</method>
</navigation_page_block_html_topmenu_gethtml_before>
</observers>
</page_block_html_topmenu_gethtml_before>
</events>
</frontend>
</config>
<?php
/**
* Created by JetBrains PhpStorm.
* User: npreuss
* Date: 4/8/13
* Time: 12:19 PM
* To change this template use File | Settings | File Templates.
*/
class Spl_Navigation_Model_Observer {
public function topmenuGethtmlBefore (Varien_Event_Observer $observer) {
$event = $observer->getEvent();
Mage::log($event->getMenu(), null, 'fsi.log');
}
}
<?xml version="1.0"?>
<config>
<modules>
<Spl_Navigation>
<active>true</active>
<codePool>local</codePool>
</Spl_Navigation>
</modules>
</config>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment