[pmwiki-users] Cookbook/OptionMenu versus JumpBox

Dominique Faure dominique.faure at gmail.com
Fri Dec 15 08:57:25 CST 2006


On 12/15/06, Roman <romat2 at gmail.com> wrote:
> Dominique,
>
> could you share with us your opinion on Cookbook/OptionMenu versus
> JumpBox? Now, I am using your Optionmenu recipe. Comparing with
> Jumpbox I prefer it because it is more author friendly - you don't
> have to define pagelist template and you don't have to do any local
> customizations, just to specify fmt=optionmenu in pagelist directive.
> I've noticed that you are active in Jumpbox threads and you also
> wrote: "One more time, I'm very pleased to have to obsolete weird
> recipes... ;)". What do you mean by this and how would you, as an
> author of OptionMenu, compare these two aproaches?

The Cookbook/OptionMenu is a "classical" php coded recipe and don't
rely on last form markup features. The recipe may even run on v2.1
(untested). You'd install it as any other recipe. The provided markup
is:

  (:pagelist group=Cookbook fmt=optionmenu:)

The Cookbook/InputJumpBox may be considered as a side effect of latest
form handling provided latest beta. It may also be considered as a
recipe since you'll need both a bit of php to define the specialized
(:input jumpbox:) form markup, and to add the dedicated pagelist
template format using it into your Site.LocalTemplates. The provided
markup is then:

  (:pagelist group=Cookbook fmt=#jumpbox:)

Technically speaking, both approaches provide the same behavior, but
the Cookbook/OptionMenu as a "closed" behavior provider is far less
flexible than the Cookbook/InputJumpBox which is only a specialization
of a core  implementated feature.
For example it's nearly impossible with Cookbook/OptionMenu to provide
conditionally forged menu item without using php code, while it's a
real piece of cake with Cookbook/InputJumpBox which requires nothing
more.

That's why I tend to consider Cookbook/OptionMenu as obsolete ie. I
won't maintain it anymore.

NB: I even just provided a way to emulate the javascript hidden submit
button alternative for Cookbook/InputJumpBox ;)

Dom




More information about the pmwiki-users mailing list