I need a quick help, need to override
app\code\core\Mage\CatalogSearch\Block\Result.php
How do I do that in my module?
app/etc/modules/Package_CatalogSearch.xml
<?xml version="1.0"?>
<config>
<modules>
<Package_CatalogSearch>
<active>true</active>
<codePool>local</codePool>
</Package_CatalogSearch>
</modules>
</config>
Now inside module, app/code/local/Package/CatalogSearch/etc/config.xml
<?xml version="1.0"?>
<config>
<modules>
<Package_CatalogSearch>
<version>1.0.0</version>
</Package_CatalogSearch>
</modules>
<global>
<blocks>
<catalogsearch>
<rewrite>
<result>Package_CatalogSearch_Block_Result</result>
</rewrite>
</catalogsearch>
</blocks>
</global>
</config>
app/code/local/Package/CatalogSearch/Block/Result.php and a class has to be defined:
class Package_CatalogSearch_Block_Result extends Mage_CatalogSearch_Block_Result
{
// some code here
}