/ Published in: PHP
A simple class to cache files (or other results) with PHP.
Expand |
Embed | Plain Text
<?php /** * Class Cache * * @author Koen Ekelschot * @license WTFPL */ class Cache { private $cachedFile; public function __construct($identifier) { } public function cacheExists($maxAge) { return true; } else { $this->invalidateCache(); } } return false; } public function getCachedCopy() { } public function getCachedFilename() { } public function cacheResult($result) { $this->invalidateCache(); } file_put_contents($this->cachedFile, $base64); } private function invalidateCache() { } } ?>
You need to login to post a comment.
