jrsaunders / quickcache
Quick Caching
Installs: 1 902
Dependents: 5
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: >=5.3
This package is not auto-updated.
Last update: 2024-11-10 05:08:58 UTC
README
Quick Caching Library
Install via composer
$composer require jrsaunders/quickcache
<?php
$setupCache = new \QuickCache\Cache();
$setupCache->setCachePath('/var/a/place/on/my/server/for/chachefiles');
$cache = new \QuickCache\Cache();
$cacheData = $cache->getCacheData('mycachefilename', 30);
if(!$cacheData){
$cacheData = //get data from DB;
$cache->saveToCache('mycachefilename', $cacheData);
}
// use the $cacheData somehow!