[Pmwiki-users] Re: Re: Re: pmwiki-0.6.21 released with experimental WikiFarm support
Christian Ridderström
chr
Wed Jun 2 14:05:10 CDT 2004
On Wed, 2 Jun 2004, Patrick R. Michaud wrote:
> On Wed, Jun 02, 2004 at 09:03:37PM +0200, Christian Ridderstr?m wrote:
> >
> > Very cool. Can this be extended for variables that you create in a
> > cookbook extension?
>
> The pages that are searched for variables are held in $VarPagesFmt
> (in vardoc.php). Are you talking about having a Cookbook.Variables
> page, or about defining variables in the various Cookbook pages and
> having them automatically picked up?
>
> Keep in mind that PmWiki has to scan wiki pages to build the variable
> documentation, and this operation could get a little expensive if a lot
> of pages have to be scanned.
I was probably thinking about using this for documenting how my site is
configured... I'm not really sure though. The simplest solution is
probably to use {{Cookbook.Variables}}, although it's a pity the variables
can't be put in the actual cookbook page (for speed reasons).
Is there a way to document the variables from inside the code?
Perhaps we could have an array with variable documentation to which you
add information like this:
$VariableDocumentation['OtherVariables']['$MyVariable'] = '
:$MyVariable: This is an example of a variable that is documented inside
the actual PHP-code.';
The description above would then automatically be appened to
{{OtherVariables}}. This would of course only work for cookbook variables
of recepies that are actually used (i.e. their code is run).
/Christian
--
Christian Ridderstr?m http://www.md.kth.se/~chr
More information about the pmwiki-users
mailing list