[pmwiki-users] New ZAP markup module...

The Editor editor at fast.st
Tue Mar 20 16:47:47 CDT 2007


On 3/18/07, The Editor <editor at fast.st> wrote:
> I'm just finishing up a new module for a new markup for ZAP variables
> suggested by Pm.  I really like the look of it, but will continue to
> maintain both markups {#c } for a while in the same module...  Then
> deprecate the old stuff later.
>
> Here's the syntax if anyone has any input:
>
> {(count)}  # of pages in current group (groupheaders, etc excluded)
> {(count Group)} # of page in that group
> {(thread)}  thread for current group
> {(thread Group)} thread for that group
> {(captcha)} random # between 10000 and 99999, all instances on same
> page = same number
> {(captcha #1|#2)} random # between #1 & #2 if not already set on page
> {(time)} current timestamp
> {(time +|change|fmt)} various options for changing current or other
> timestamp and formatting
> also takes normal english phrases and can convert to timestamp.  Many options
> {(time #|fmt)} returns corresponding day of week or day of month
> depending on # and configurable list.  Quite flexible actually.
> {(math (2+3) * 7 /4)}  Returns 8.75
> {(substr adfsasfdasf,3,4)} Returns sasf.  Can take any other php
> command defined in list: default includes
> substr,strpos,strtotime,strftime,date,crypt,rand.
>
> Any questions or comments before I release the new module?
>
> Cheers,
> Dan
>
> PS.  This module works completely independently of ZAP, and ZAP works
> completely independently of it.  It did requiring reworking
> (duplicating, really) a couple small functions so neither module calls
> functions the other.


I've just finished adding in the alternate directive markup with the
following directives available (this is useful for embedding
directives in hidden text vars, esp via zap forms):

table,tableend,cell,cellnr,include,if,pagelist,input,zapform,zap,zapend,
messages,redirect

I'm hoping all of these process after vars in the markup table...  If
anyone has another favorite they'd like to see in the list, I'll be
uploading the new module shortly.

Cheers,
Dan

PS.  Several other small fixes and minor tweaks.  Thanks to Ben for
all the help combing through the documentation, etc.



More information about the pmwiki-users mailing list