PHP Classes

Super Simple Cache: Cache the contents of remote Web pages

Recommend this page to a friend!
     
  Info   Example   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 70%Total: 244 All time: 7,996 This week: 71Up
Version License PHP version Categories
supersimplecache 1.0GNU General Publi...5PHP 5, Files and Folders, Cache
Description 

Author

This class can cache the contents of remote Web pages.

It can check if a local cache for a given page URL exists.

If it exists and it was not created more than a cache maximum age period, the class returns the current cached data.

If the cache file does not exist or it has expired, the class retrieves the page from the given URL and stores its contents in the local cache file before returning the contents string.

Picture of Silvio
  Performance   Level  
Name: Silvio <contact>
Classes: 2 packages by
Country: Brazil Brazil
Age: ???
All time rank: 3278250 in Brazil Brazil
Week rank: 215 Up19 in Brazil Brazil Up

Example

<?php

include('SuperSimpleCache.php');

$ssc = new SuperSimpleCache('/home/user/www/data/', 15);

echo
$ssc->get('https://www.phpclasses.org');


  Files folder image Files (2)  
File Role Description
Plain text file cache-test.php Example Using example
Plain text file SuperSimpleCache.php Doc. Main file

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:244
This week:0
All time:7,996
This week:71Up
 User Ratings  
 
 All time
Utility:100%StarStarStarStarStarStar
Consistency:100%StarStarStarStarStarStar
Documentation:-
Examples:100%StarStarStarStarStarStar
Tests:-
Videos:-
Overall:70%StarStarStarStar
Rank:299