CachedNumberOfArticles

Summary: Count pages in wiki
Version: 2016-01-13
Prerequisites:
Status: Stable
Maintainer: Anomen
Categories: Includes
Users: (view? / edit)

Description

This recipe reports number of articles in wiki. Value is obtained from cache unless optional refresh argument is specified.

Usage

Installation

Copy noa.phpΔ into your cookbook dir.

Add to local/config.php:

  require_once($FarmD . '/cookbook/noa.php');  

Markup usage

  • Use (:numberofarticles:) to display number of articles.
  • Use (:numberofarticles refresh:) to update counter and display correct number of articles.

Notes

  • Number of articles is cached in $WorkDir/.noa.
  • Pages in wikilib.d (i.e. default articles in groups Site and PmWiki) are excluded.
  • This recipe should work with PerGroupSubDirectories.

See Also

git repository
https://github.com/anomen-s/pmwiki-recipes/tree/master/CachedNumberOfArticles

Contributors

Comments

See discussion at CachedNumberOfArticles-Talk

User notes? : If you use, used or reviewed this recipe, you can add your name. These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki.