CC-Cache

plugin banner

A simple and fast cache plugin based on static-rendered html files served by Apache with mod_rewrite.

Author:Clearcode | Piotr Niewiadomski (profile at wordpress.org)
WordPress version required:4.4.2
WordPress version tested:4.6.28
Plugin version:1.3.1
Added to WordPress repository:18-04-2016
Last updated:03-10-2016
Warning! This plugin has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.
Rating, %:0
Rated by:0
Plugin URI:https://wordpress.org/plugins/cc-cache
Total downloads:1 514
Active installs:10+
plugin download
Click to start download

The CC-Cache plugin supports caching of Posts, Pages, and any public Custom Post Types – including single and archive pages.
It also supports a “static page display” option: Front page, Posts page, and standard Latest Posts listing.
This plugin is compatible with Multisite WordPress installations.

How does it work?

When a user (i.e. someone who is logged out of WordPress) opens a page for the first time, the plugin saves all the rendered html to a file in the wp-content/cache directory.
From this moment onwards, any user who accesses the site will be served content directly from the generated html file. WordPress at this point is not initialized for this page.
The generated cache file will be removed when you make changes to the corresponding Post/Page, and then the process starts from the beginning.
You can also clear all cached files from the Cache options page (visit the ‘Settings > Cache’ page in wp-admin), or manually delete files from the wp-content/cache directory.

Tips & Tricks

You can check if a page’s content is served from a cache file by opening the page’s source code in the browser and scrolling down to the closing <body> html tag.
If the content is cached, you should see a comment with the date and time the page was last cached, for example:

You can disable cache for a single request and get the raw html by adding cache=false to a URL’s parameter, for example:
http://example.com/?cache=false

You can disable cache for a single request and get the raw html by adding cache=false HTTP header.

Logged-in users always get the raw html.

Ideas for future versions

  1. Add support for Categories, Tags, Taxonomies, and Authors.
  2. Add support for RSS/Atom feeds.
  3. Add support for Nginx and IIS servers.
  4. Add support for other WordPress Filesystem Methods.
  5. Add regenerate function for all cache files.

Requirements

  1. Apache server
  2. mod_rewrite
  3. Write access to wp-content/cache directory
  4. PHP interpreter version >= 5.3

Screenshots
ChangeLog