[pmwiki-users] ZAP and "fun with forms"

The Editor editor at fast.st
Fri Apr 20 04:39:10 CDT 2007


On 4/20/07, Hans <design5 at softflow.co.uk> wrote:

> If PmWiki's form processing gets extensible in such manner I am
> looking forward to scrap Fox. :)


ZAP will likely make the same change if:

1) I can get some help figuring out how to best plug in ZAP's many
"commands". (They are mostly all separate functions already, and the
ZAP engine is set up similar to Petko's suggested code--so it may not
be too hard.). I basically need to be able to take all post values,
add the ZAP session array, use a foreach loop to call all requested
functions, and then be able to pass perhaps a completely new POST
array on to the PmWiki processor for saving as PTV values.

2) I can be reasonably reassured the security of this processing
approach will be sufficient for the kinds of commands in ZAP.  (Some
are quite powerful). I'm curious what mechanism Pm is using to
validate each post submission for authenticity. It may not be that
critical for  PTV replacement, but for deleting pages, resetting
passwd attributes, sending emails, or authenticating members, Pm may
recommend tougher security.

ZAP may also wait till the page insertion (comments) come out, as that
will also make a major impact on how it (and Fox) works. That way
there could be one major upgrade instead of two. I suspect this is
likely to be done soon now that Pm is in heart of the forms processing
phase of this round of beta development. I think that is one of the
last things still slated on his roadmap.

I am considering however:

Simply hijacking the input markup definition, so ZAP can use the same
$:field syntax (optionally) to prefill forms and continue using ZAP as
it is now. Or perhaps there could be a flag that can turn Pm's
processor off, so recipes can use Pm's remapped POST values and
process them their own way. Or if Pm builds a hook for other
pre-processing engines then the preprocessor could likely be set to
not return to the main core processor if wished.

I like the simplicity of the syntax (a lot), but feel a bit limited by
how it works. It would be great to have it prefill a form fields with
data, but would prefer to continue using the savedata command. It
allows me to save only the specific fields I want and at specific
point in the forms processing.  Or even save data on two or three
differents pages in the same form.  If I took this approach, then I
could also continue to use the datapage command. In general ZAP's
syntax seems a bit less cryptic, but probably only because I've spent
so much time working with it.

I'm wondering if Pm, or any current ZAP users have input on the
direction ZAP should pursue?

Cheers,
Dan



More information about the pmwiki-users mailing list