[pmwiki-users] HtmlCache, Internationalizazion, layout problem

Patrick R. Michaud pmichaud at pobox.com
Tue Jul 18 21:07:40 CDT 2006


On Wed, Jul 19, 2006 at 12:57:32AM +0200, Thomas Bley wrote:
> Thanks,
> 
> What about using a page directive to enable/disable caching: (analog to 
> "(:title blabla:)"):
> (:url_cache time=3600:)
> 
> This settings allows a page to be cached as Html. The cache file is used 
> for 1 hour.
> So each author can decide if the page is cached or not. Also a setting 
> per Group may be possible.

Authors (or else PmWiki) still need to be smart enough not to cache
read-protected pages or pages that are somehow "dynamic".

But if you want to try PmWiki's built-in caching (which already is
smart enough to know how long to cache pages, and to not cache pages
that depend on the visitor's identity or other timing items), then 
try the following in config.php:

    $PageCacheDir = 'cache.d';
    $EnableHTMLCache = 1;

It can also be done on a per-group or per-page basis in local
customization files.

> This would be very good for pages that don't change very often, but get 
> viewed very frequently by the users.
> On my site there are ~60000 views per month and ~40000 go only to the 
> first page (which has many includes). So if I cache it better, the whole 
> machine speeds up.

For whatever it's worth, the pmwiki.org site gets ~800,000 views
per month with no caching.  (A "view" here is a request for a wiki
page; i.e., it's exclusive of requests for uploads, css files,
images, etc.)

Pm





More information about the pmwiki-users mailing list