I was wondering if there is any way for disabling pyrocache in pyrocms? The library gets loaded in MY_Controller instead of autoload.php, so I don't know if there are any other simple ways.
3 Answers
In case you were trying to disable the cache for development purposes, which is completely reasonable, you can do what I did, and add return;
to the first line of function write()
within system/cms/libraries/Pyrocache.php
, then go into Utilities -> Maintenance -> Cache Maintenance and empty everything.
This will prevent the CMS from creating new cache files. Just don't forget you added this!

- 76
- 3
-
A similar trick I stumbled on accidentally is to make the cache folder not writable, `chmod 000`. The cache won't complain, it just simply won't do anything. – parker.sikand Jan 22 '14 at 20:36
If you disable the cache then you are asking your server to do way more work than it should. PyroCMS is not inefficient, but it will be slower than it needs to be if you disable this.

- 30,637
- 12
- 78
- 117
Well, you can't - because you shouldn't.
Rendering the pages rely on PyrosCMS's cache library. If you don't load the library (like if you comment the loading of the cache library out in MY_Controller), the site will probably throw a fatal error when trying to access it, since the pages module use it for a lot of things.

- 15,015
- 8
- 54
- 79