Magento cache problem
I have a weird problem with Magento cache.
I have an extension that have a Block output. If I change anything in the Block/* code it is not reflected in the front-end. If I delete anything in the Block/* it is not reflected at the front end. If I disable the module or delete e开发者_如何学Gotc/config.xml it does reflected at the front-end.
Cache is disabled and additionally I ran rm -fr var/cache/* before I refresh browsers page.
Please advise.
UPDATE:
This is Magento 1.3.2.3, so there's no System --> Tools --> Compilation menu nor shell/compiler.php. I found the following code in index.php:
/**
* Error reporting
*/
error_reporting(E_ALL | E_STRICT);
/**
* Compilation includes configuration file
*/
$compilerConfig = 'includes/config.php';
if (file_exists($compilerConfig)) {
include($compilerConfig);
}
but there's no includes folder at all so I think compiler is not the issue.
Also here is the code of config.xml of my module:
<?xml version="1.0"?>
<config>
<global>
<blocks>
<googleanalytics>
<rewrite>
<ga>Namename_GoogleAnalytics_Block_Ga</ga>
</rewrite>
</googleanalytics>
</blocks>
</global>
</config>
UPDATE:
Look for my self-ansver for the solution (quite a dumb).
Do you have the Magento compiler turned on? This would cause problems that behave in the way you specify.
The config.xml
should have the following code:-
<?xml version="1.0"?>
<config>
<modules>
<Namename_GoogleAnalytics>
<version>1.0</version>
</Namename_GoogleAnalytics>
</modules>
<global>
<blocks>
<namenamegoogleanalytics>
<class>Namename_GoogleAnalytics_Block</class>
</namenamegoogleanalytics>
<googleanalytics>
<rewrite>
<ga>Namename_GoogleAnalytics_Block_Ga</ga>
</rewrite>
</googleanalytics>
</blocks>
</global>
</config>
Also other than the "blocks
" & "global
" nodes, you may need to provide other nodes as required.
Hope it helps.
Ok, it turned out to be quite a dumb but I agree with Joseph Mastey and maybe it will help anyone else ran into this issue.
The problem was solved by another extension overriding the same class. So either disable rival extension, edit it or modify tags.
精彩评论