PreferencesPlugin
Allows editing of preferences using fields predefined in a
TWikiForms. However, the edit fields are inlined in the text, similar to how tables are edited in
TWiki:Plugins/EditTablePlugin.
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 TWikiForms 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.
Examples
-
%EDITPREFERENCES{ "%TWIKIWEB%.TWikiPreferencesForm" }%
Plugin Settings
Plugin settings are stored as preferences variables. To reference a plugin setting write
%<plugin>_<setting>%
, i.e.
%PREFERENCESPLUGIN_SHORTDESCRIPTION%
- One line description, is shown in the TextFormattingRules topic:
- Set SHORTDESCRIPTION = Allows editing of preferences using fields predefined in a form
Plugin Installation Instructions
Note: You do not need to install anything on the browser to use this plugin. The following instructions are for the administrator who installs the plugin on the server where TWiki is running.
- Download the ZIP file from the Plugin web (see below)
- Unzip
PreferencesPlugin.zip
in your twiki installation directory. Content: File: | Description: |
data/TWiki/PreferencesPlugin.txt | Plugin topic |
data/TWiki/PreferencesPlugin.txt,v | Plugin topic repository |
lib/TWiki/Plugins/PreferencesPlugin.pm | Plugin Perl module |
data/TWiki/TWikiPreferencesForm.txt | Example form |
- (Dakar) Visit
configure
in your TWiki installation, and enable the plugin in the {Plugins} section.
- If the installation was successful, an edit button should appear below:
Plugin Info
Related Topics: TWikiPreferences,
TWikiForms
--
TWiki:Main.ThomasWeigert - 08 May 2005