OptionMenu

Summary: Get page listings as an option menu selector
Version: 2010-02-18
Status: Stable
Prerequisites: pmwiki-2.x
Maintainer: Dfaure
Discussion: OptionMenu-Talk
Users: +2 (View / Edit)

Description

The fploptionmenu.phpΔ script provides the extra optionmenu pagelist format which enables page navigation through a dropdown menu:

Here is it: (:pagelist group=Cookbook fmt=optionmenu:)

Here is it:

Notes

The (:pagelist ... fmt=optionmenu:) execution renders in an option menu populated with the pagename fetched by the directive, and a "Go" button to reach the selected page.

Javascript enabled browser would have the button kept hidden and page navigation triggered directly by selection changes.

The new format option understands the following (:pagelist:) extra directives:

form=NAME
The name to apply to the resulting form (defaults to optionmenu),
size=SIZE
The option menu field size (defaults to 1),
selclass=CLASS
The css style class to use for the option menu field (defaults to inputbox).

Caution: Do not forget to set unique names when using several forms on the same page.

The following customization variables are available:

$FPLOptionMenuFmt
The fetched page option text template (defaults to '\$Titlespaced').
$EnableFPLOptionMenuJS
Allow Javascript navigation for enabled browser (defaults to 1).
$FPLOptionMenuOpt
Predefined (:pagelist:) extra directive values.

Contributors

Dfaure

See Also

Release Notes

2010-02-18
Fixed long standing xhtml validation bug. Thanks Holger.
2007-11-06
Internal fixes. Added handling of count=... option.
2006-11-30
Initial release.

User notes +2: If you use, used or reviewed this recipe, you can add your name. These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki.