[pmwiki-users] Is there a way to display the number of revisions for a page?
Jonathan Scott Duff
duff at pobox.com
Sat Jan 29 23:16:10 CST 2005
On Sat, Jan 29, 2005 at 11:11:47PM -0600, Jonathan Scott Duff wrote:
> On Sat, Jan 29, 2005 at 10:52:38PM -0600, Jonathan Scott Duff wrote:
> > On Sat, Jan 29, 2005 at 08:10:29PM -0800, Noel Llopis wrote:
> > > I'd like to indicate how many revisions a page has gone through (I
> > > find it's a very good indication of how busy the page has been and
> > > it's quite useful). Is there a way to do that with PmWiki? I've
> > > looked through the available variables but didn't see anything
> > > about that.
> >
> > There's probably a better way to do this, but ...
>
>
> I just looked. There *was* a better way :-) Add the following to
> your local/config.php:
>
> Markup('showrev','inline','/\{\$Rev\}/e',
> "\$GLOBALS['PCache'][\$pagename]['rev']");
Oops, that should really be
Markup('showrev','inline','/\{\$Rev\}/e',
"\$GLOBALS['PCache'][\$pagename]['rev']+0");
For those pages that have been editted 0 times to actually show a 0
rather than the empty string.
-Scott
--
Jonathan Scott Duff
duff at pobox.com
More information about the pmwiki-users
mailing list