Insert the %EDITPREFERENCES% variable (see below) anywhere in your topic. It will be replaced by a button that allows editing each preference in its predefined input format (or a text box, when no format is defined for this preference).

In edit mode, the edit button is replaced by Save and Cancel buttons, with their obvious meanings.

Syntax Rules

%EDITPREFERENCES{ "topic" }%

topic references a TWikiForm defining the format of the edit fields for preferences. It may be prefixed by a web.

If a preference setting is not mentioned in the form referenced by topic, a text input box of the specified length is provided.

Otherwise, the input can be through textareas, select, radio, checkbox, date, or text, as provided by TWikiForms.

Adding css classes to buttons. Removed debug print statement causing 500s on SunOne. Prevent extra space in settings on saves. Switched to earlier handler. Converted all SCRIPTURL to SCRIPTURLPATH, and added support. The only SCRIPTURLs should be the one in the BASE tag and those in mail notification templates. Because the forms package was throwing an exception when it failed to create a form, the edit preferences plugin was aborting the whole of the session whenever the form specified in EDITPREFERENCES didn't exist. Changed it so that the Form constructor does not throw, but returns undef on a non-existant form, and changed preferences plugin to be tolerant of missing forms (ie defaults all fields to text if the form is missing, of is a Set exists which is not in the form).

26 May 2005:

Crawford Currie recoded to use code from Form.pm to render form fields.