Question
How do I create a variable to include on a
WikiPage that would display the word count for that page?
Environment
--
StevenSchulman - 21 Jul 2004
Answer
There is no ready made way to do this. However with some programming it can be done with a plugin something like this: Create a new Plugin, could be called
TopicInfoPlugin that expands a
%TOPICINFO{}% variable. It could be made to understand tokens like
$wordcount,
$charcount and
$lines, so that you can write
%TOPICINFO{ "Word count: $wordcount, number of lines: $lines" }%. It could also understand additional parameters like
topic="SomeTopic".
To create the Plugin follow the instructions in
TWikiPlugins, you can also get some ideas by studying existing Plugins like the
LocalCityTimePlugin.
Perl knowledge is assumed.
CodersForHire could help if you aren't a programmer.
--
PeterThoeny - 21 Jul 2004, --
MattWilkie 27 Jul 2004