none
[openafs-wiki.git] / TWiki / TWikiPlugins.mdwn
1 ## <a name="TWiki Plugins"></a> TWiki Plugins
2
3 Plugins allow you to extend the syntax or functionality of TWiki. ...
4
5 [[TWikiPreferences]] has the list of installed plugins and activated plugins.
6
7 ### <a name="How to Create a Plugin"></a> How to Create a Plugin
8
9 under construction... ( check back at <http://TWiki.org/cgi-bin/view/TWiki/TWikiPlugins> )
10
11 ### <a name="How to Install a Plugin"></a> How to Install a Plugin
12
13 under construction... ( check back at <http://TWiki.org/cgi-bin/view/TWiki/TWikiPlugins> )
14
15 ### <a name="Plugins under the hood"></a> Plugins under the hood
16
17 - All plugin modules that exist in the `lib/TWiki/Plugins` directory are activated automatically unless disabled by the `DISABLEDPLUGINS` preferences variable in [[TWikiPreferences]]. You can optionally list the installed plugins in the `INSTALLEDPLUGINS` preferences variable. This is useful to define the sequence of plugin execution, or to specify other webs then the %WIKITOOLNAME% web for the plugin topics. Settings in [[TWikiPreferences]]:
18   - `Set INSTALLEDPLUGINS = DefaultPlugin, ...`
19   - `Set DISABLEDPLUGINS = EmptyPlugin, ...`
20
21 - The `%ACTIVATEDPLUGINS%` variable shows all currently activated plugins. This variable is shown in [[TWikiPreferences]] for debug reasons.
22
23 - Search order for plugin topics: Full `web.topicname` name is used if specified in `INSTALLEDPLUGINS`, then the TWiki web is searched, then the current web.
24
25 - Plugin specific settings are done in individual plugin topics. Two settings are standard for each plugin:
26   - One line description, used to form the bullets describing the plugins in the [[TextFormattingRules]] topic:
27     - `Set SHORTDESCRIPTION = Blah blah.`
28   - Debug plugin, output can be seen in `data/debug.txt`: (Se to 0 or 1)
29     - `Set DEBUG = 0`
30   - The settings can be retrieved as preferences variables like `%<pluginname>_<var>%`, i.e. `%DEFAULTPLUGIN_SHORTDESCRIPTION%` shows the description of the DefaultPlugin.
31
32 - The `%PLUGINDESCRIPTIONS%` variable shows a bullet list with descriptions of all currently activated plugins. This variable is based on `%<plugin>_SHORTDESCRIPTION%` preferences variables of individual topics and is shown in [[TextFormattingRules]].
33
34 -- [[PeterThoeny]] - 14 Jul 2001 <br />