[pmwiki-devel] PmWiki request

The Editor editor at fast.st
Tue Dec 12 07:03:03 CST 2006

On 12/12/06, Hans <design5 at softflow.co.uk> wrote:
> You know, seeing conditionals inside (:input :) markup makes me cringe.
> I know you try to create shorter syntax for ZAP.
> But you go against what people learned and know in PmWiki.
> You seem to have hijacked PmWiki's (:input:) markup
> and made something quite different out of it.

Actually this is something very different Hans.  This is not a
shortcut for the standard PmWiki conditional but rather a completely
different conditional for processing a form submission after it is
posted.  It makes no change to how conditionals work in PmWiki, and it
is not an alternate markup,  But it does allow some nice possibilities
in terms of forms processing.  That's all I'm looking at trying to do.

> To me any (:input ... :) should be only used to create form elements.
> Conditions as to when a form element shall be added to HTML output
> should stay out of the markup, as it is already possible with
> (:if ... :) markup. Manipulating any page variable used inside (:input
> :) should also stay outside of the markup.

I didn't change any of the markups for forms (other than adding very
simple, and temporary, select/textarea markups to do some basic forms
things.  ZAP is actually only a forms processing engine that takes a
form submission and proccesses it in various ways based on the input
fields submitted.  Actually you can use any kind of form input markup
with zap as long as it produces a valid $_POST variable.  All
functions take place after submission.

> I think it is okay to add features to existing PmWiki markup, in order
> to make it perhaps more powerful or user friendly. But doing so one
> needs to be careful to preserve the features and functionality already
> there, and not rewrite the whole syntax. Otherwise it feels like
> putting a pig's skin onto a sheep.

The request to core I'm making is only to split one bigger function
into two parts so I can access just the part I need (return
true/false), rather than both (check true/false and then return/don't
return markup).  I need the true/false part not the markup.  It should
involve no change to any existing site or markup.  Only adds another
hook for any recipe writer who wants to tap into PmWiki's conditional
testing system.

> Right now I would not know if PmWiki's (:input:) form markup still
> works when installing ZAP, or is replaced or partial replaced.
> And I see a lot of unfamiliar syntax not very intuitive to me from
> what I learned so far in PmWiki. Which makes me wonder how ZAP
> integrates into Pmwiki, and makes me extremely wary about it.

If you do install ZAP it will make absolutely no change to any
existing input markups.  And you can still use all your existing forms
as they are.  The zap processing engine is only called if you wrap a
form in (:zapform:) and (:zapend:) rather than (:form:) and

Hope this helps clarify things a bit.


More information about the pmwiki-devel mailing list