I'm trying to override the Catalog Layer class of Magento 1.9 so that not working after longs times to find error :(
No errors in logs, module work correctly except model rewrite.
app/etc/modules/comx_fab.xml:
<?xml version="1.0"?>
<config>
<modules>
<Comx_Fab>
<active>true</active>
<codePool>local</codePool>
<depends>
<Mage_Catalog />
</depends>
</Comx_Fab>
</modules>
</config>
app/code/local/Comx/Fab/etc/config.xml:
<?xml version="1.0"?>
<config>
<modules>
<Comx_Fab>
<version>0.2.0</version>
</Comx_Fab>
</modules>
<global>
<blocks>
<catalog>
<rewrite>
<product_list_toolbar>Comx_Fab_Catalog_Block_Product_List_Toolbar</product_list_toolbar>
</rewrite>
</catalog>
<page>
<rewrite>
<html_topmenu>Comx_Fab_Page_Block_Html_Topmenu</html_topmenu>
</rewrite>
</page>
</blocks>
<models>
<catalog>
<rewrite>
<layer>Comx_Fab_Catalog_Model_Layer</layer>
</rewrite>
</catalog>
</models>
</global>
</config>
app/code/local/Comx/Fab/Catalog/Model/Layer.php:
<?php
class Comx_Fab_Catalog_Model_Layer extends Mage_Catalog_Model_Layer {
/**
* Initialize product collection
*
* @param Mage_Catalog_Model_Resource_Eav_Mysql4_Product_Collection $collection
* @return Mage_Catalog_Model_Layer
*/
public function prepareProductCollection($collection) {
exit('Good!');
}
}
Already done:
- cache refresh, "cache" folder deleted,
- compare my magento code to current magento release (no diff)
- check owner/chmod