Jump to content

Cronjob to flush the compiled cache for a single module


mikeshop

Recommended Posts

Hi,
I try to empty the cache of a single module every 24 hours, I tried some solution but it did not work

Who can i clear cache of module for example /modules/abc/ on Prestashop 1.7

require('/config/config.inc.php');
$this->context->smarty->clearCompiledTemplate("abc.tpl");

Any help please ?

Link to comment
Share on other sites

  • 3 months later...
  • 3 years later...

UNTESTED:

https://prestacraft.com/programmatically-cache-clearing-in-prestashop/#

 I'm probably gonna test it tonight. Yet I'd put it into the admin folder which in my case is .htaccess blocked "require all denied" except for certain office IP's which makes it most secure. Putting it into the root is kinda dumb as it's not something that is for the customers to execute but administrators...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...