PHPackages                             rodrigoalviani/php-simple-cache - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Caching](/categories/caching)
4. /
5. rodrigoalviani/php-simple-cache

ActiveLibrary[Caching](/categories/caching)

rodrigoalviani/php-simple-cache
===============================

PHP class to cache dynamic pages in file and reduce Database overload.

v0.1.0(11y ago)017MITPHPPHP &gt;=5.3.0

Since Dec 22Pushed 11y ago1 watchersCompare

[ Source](https://github.com/rodrigoalviani/php-simple-cache)[ Packagist](https://packagist.org/packages/rodrigoalviani/php-simple-cache)[ Docs](https://github.com/rodrigoalviani/php-simple-cache)[ RSS](/packages/rodrigoalviani-php-simple-cache/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

PHP Simple Cache
================

[](#php-simple-cache)

PHP class to cache dynamic pages in file and reduce Database overload

Install
-------

[](#install)

Install via [composer](https://getcomposer.org):

```
{
    "require": {
        "rodrigoalviani/php-simple-cache": "~0.1"
    }
}
```

Run `composer install` then use as normal:

```
require 'vendor/autoload.php';
$cache = new Rodrigoalviani\Cache\Cache($label);
```

Usage
-----

[](#usage)

A very basic usage example:

```
$cache = new Rodrigoalviani\Cache\Cache($_SERVER['REQUEST_URI']);
$cache->cacheInit();

// your page here

$cache->cacheEnd();
```

A more advanced example:

```
$cache = new Rodrigoalviani\Cache\Cache($_SERVER['REQUEST_URI']);
$cache->set_filePath('tmp/');
$cache->set_cacheMaxAge(84600);
$cache->set_cacheExtension('.tmp');
$cache->cacheInit();

// your page here

$cache->cacheEnd();
```

Credits
-------

[](#credits)

PHP Simple Cache was created by [Rodrigo Alviani](http://github.com/rodrigoalviani). Released under the MIT license.

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

4160d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/6d638c1ef5aa9385dbee9ba25906d84c051a4c2b72ccc28377ace51bee1e4de7?d=identicon)[rodrigoalviani](/maintainers/rodrigoalviani)

---

Top Contributors

[![rodrigoalviani](https://avatars.githubusercontent.com/u/5366090?v=4)](https://github.com/rodrigoalviani "rodrigoalviani (12 commits)")

---

Tags

cache

### Embed Badge

![Health badge](/badges/rodrigoalviani-php-simple-cache/health.svg)

```
[![Health](https://phpackages.com/badges/rodrigoalviani-php-simple-cache/health.svg)](https://phpackages.com/packages/rodrigoalviani-php-simple-cache)
```

###  Alternatives

[psr/simple-cache

Common interfaces for simple caching

8.1k727.3M2.1k](/packages/psr-simple-cache)[psr/cache

Common interface for caching libraries

5.2k686.9M1.3k](/packages/psr-cache)[react/cache

Async, Promise-based cache interface for ReactPHP

444112.4M40](/packages/react-cache)[beste/in-memory-cache

A PSR-6 In-Memory cache that can be used as a fallback implementation and/or in tests.

2512.2M6](/packages/beste-in-memory-cache)[anahkiasen/flatten

A package for the Illuminate framework that flattens pages to plain HTML

33313.0k](/packages/anahkiasen-flatten)[rtcamp/nginx-helper

Cleans nginx's fastcgi/proxy cache or redis-cache whenever a post is edited/published. Also provides cloudflare edge cache purging with Cache-Tags.

23817.0k1](/packages/rtcamp-nginx-helper)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
