Clear cache at specific time?


I’v done a new startpage that lists events happening the current date.

So i wonder if its possible to configure comet cache to reset at a specicied time? Like midnight each day? Or do i need to manually code a script and run it via cron?

Setting the interval at 24 hours doesnt cut it as i can tell, as if the last clear was 23:30 last night, it will show yesterdays startpage the whole day.

If you set the Expiration Time to 1 day, then no cache file will be allowed to exist for more than 1 day. However, that 1 day is calculated from the time the cache file was created. If you wanted a shorter amount of time, you could use 12 hours instead of 1 day for the Expiration Time.

Another option would be to use the Comet Cache API to set up a script that runs at a specific time to clear the cache for that specific page.

Thank you @raamdev , i figured a tight interval or a crontabbed script were options. Just wanted to check if there was a simpler way to just config the plugin to use timestamps instead of invervals.

It’s not currently possible to define a specific time to clear the cache, but we do have a feature request open here:

I’ve added a note about this thread to that issue.