Joomla has a nice "Clear Cache" page that lists cached content and lets you delete it.
I'd like to allow cached content from my module to be deleted from there. I'm using Joomla's built-in cache methods to cache data:
$cache = JFactory::getCache(); $cache->setCaching( 1 ); $result = $cache->call('function', $data);
The files generated by this code are stored in /cache. For example:
The folder at /cache/banners is where I would like the cache files to be stored. That's because in the "Clear Cache" page, only sub-directories seem to be clearable:
I've taken a look through Joomla's api, but I don't see any obvious methods for setting the cache directory. I do see some methods mentioning things like "cache groups", which seems close. Am I on the right track?