Control naming of topics
This plugin allows you to enforce a certain policy for topic names by defining
a set of rules. Each rule consists of
- a regular expression pattern
- an error message, and
- a flag
When a topic is to be edited or saved, the regular expressions are checked. Each
rule can be flagged
deny or =allow. All rules are processed in the order given.
The first pattern that matches either forbids or allows the topic to be processed
any further. For instance, the example only allows topics names to consist of
characters a-z, A-Z, digits 0-9, the dot and a slash. Dot and slash are needed
as the match is tested against the fully qualified topic name consisting of the
web and topic part, separated by a dot. That way you can create different rules for
different webs.
Several topics can be specified using
- Set TOPICVALIDATION_PLUGIN_RULESET = TopicNameRuleSet1, TopicNameRuleSet1, ...
(defaults to
TopicNameValidationPlugin? )
Each ruleset topic is parsed for a table in the format given below and all rules
are concatenated.
If a topic name is forbidden, the user is redirected to
oopstopicname. That's
where the
error message is inserted as specified in the second column of the
rule set.
A rule can be disabled temporarily by adding
disabled to the third column.
Installation Instructions
You do not need to install anything in the browser to use this extension. The following instructions are for the administrator who installs the extension on the server.
Open configure, and open the "Extensions" section. Use "Find More Extensions" to get a list of available extensions. Select "Install".
If you have any problems, or if the extension isn't available in
configure, then you can still install manually from the command-line. See
http://foswiki.org/Support/ManuallyInstallingExtensions for more help.
Plugin Info
Sponsored by