PHP code example of wendelladriel / cache-ttl-helper
1. Go to this page and download the library: Download wendelladriel/cache-ttl-helper library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
wendelladriel / cache-ttl-helper example snippets
use WendellAdriel\CacheTtlHelper\CacheTTL;
CacheTTL::second(); // 1s
CacheTTL::seconds(30); // 30s
CacheTTL::minute(); // 60s
CacheTTL::minutes(5); // 300s
CacheTTL::hour(); // 3600s
CacheTTL::hours(2); // 7200s
CacheTTL::day(); // 86400s
CacheTTL::days(3); // 259200s
CacheTTL::week(); // 604800s
CacheTTL::weeks(2); // 1209600s
CacheTTL::month(); // 2592000s
CacheTTL::months(6); // 15552000s
CacheTTL::year(); // 31536000s
CacheTTL::years(2); // 63072000s