Disabling Cache in Silverstripe 3.1

While working with Silverstripe we found ourselves having to run “?flush=1″ a lot to clear the Cache. To switch it off, while you work, add the following to your mysite/_config.php:

 

Bookmark and Share

2 thoughts on “Disabling Cache in Silverstripe 3.1

  1. basedrop

    Works on 2.4.13 thank you.

    We are working with subversion and three versions of our code:

    Local = I put this line in my _localConfig.php to kill caching on my local

    Dev (a staging server published to the web)= _localConfig.php is not part of the version control deployment so I created and added this file manually via ftp  This file only contains this line of code, not all my local config code.  Caching is turned off now on our dev.  You’ll have to do one final flush=all to clear out the current contents of the cache.

    Live (the real site) = Live still has caching turned on as _localConfig.php is not part of the deployment.

     

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">