Search code examples
magentocachingmagento2

Magento override template only once


I have magento Magento 2.4.3

I create a module to ovveride the Logo. It works.

After first enable i see my new logo in

app\code\MyVendor\MyModule\view\frontend\templates\html\header\logo.phtml

I edited again the template but i can't see my new edits.

I tried all this command:

rm -rf generated
rm -rf var/cache
rm -rf var/generation

php bin/magento setup:upgrade
php bin/magento cache:clean
php bin/magento cache:flush

But i see always my first code. Why? Where magento have this file files persisting?


Solution

  • I found solution. It was php cache. I use

    opcache_reset() 
    

    Before clean Magento Cache