PHP code example of sylweriusz / webcache-middleware
1. Go to this page and download the library: Download sylweriusz/webcache-middleware 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/ */
sylweriusz / webcache-middleware example snippets
$app->add(new \Slim\Middleware\WebcacheRedis('192.168.1.12:6379'));
$webcache = new \Slim\Middleware\WebcacheRedis('192.168.1.12:6379');
$webcache->delete(123456);
\Slim\Middleware\WebcacheRedis::setTtl(0);
\Slim\Middleware\WebcacheRedis::setTtl(600);