key Log In or Register to edit

TopicReferencePlugin

This plugin is used to help find orphaned topics. It can also be used to count the number of references to a particular topic.

Syntax Rules

  • Lists are generated with the following:
    • %TOPICREFERENCELIST{"(argument)" [web="webname"]}%

Argument Description
orphans Show all topics with a ref count of 0 (default if you used %TOPICREFERENCELIST{}%)
hasref Show all topics with references (excluded orphans)
all Show all topics for the web and their reference counts (e.g. number of times a topic is referenced from another topic)

Syntax Examples

  • List orphaned topics
    • %TOPICREFERENCELIST{"orphans"}%
    • %TOPICREFERENCELIST{}%

  • List orphaned topics in a different web
    • %TOPICREFERENCELIST{"orphans" web="MyWeb"}%

  • List topics with references (non-zero)
    • %TOPICREFERENCELIST{"hasref"}%

  • List all topics and reference counts
    • %TOPICREFERENCELIST{"all"}%

Rendered Example, Orphans in the Main web

Plugin output (pre-rendered):

Plugin output (if enabled):

%TOPICREFERENCELIST{"orphans" web="Main"}%

Used syntax:
%TOPICREFERENCELIST{"orphans" web="Main"}% 

Plugin Settings

  • One line description, is shown in the Text Formatting Rules topic:
    • Set SHORTDESCRIPTION = Find orphaned topics or topic ref counts.

  • Debug plugin: (See output in data/debug.txt)
    • Set DEBUG = 0

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 TWiki server.

  • Download the ZIP file from the Plugin web (see below)
  • Unzip TopicReferencePlugin.zip in your twiki installation directory. Content:
    File: Description:
    data/TWiki/TopicReferencePlugin.txt Plugin topic
    data/TWiki/TopicReferencePlugin.txt,v Plugin topic repository
    lib/TWiki/Plugins/TopicReferencePlugin.pm Plugin Perl module
  • Configure the Plugin:
    • TWiki 4.0 and up: Run the configure script to enable the Plugin
    • Change the Plugin settings as needed
  • Test if the installation was successful (verify rendered example above)

Plugin Info

Plugin Author: TWiki:Main.JeffCrawford
Copyright: © 2006, TWiki:Main.JeffCrawford
License: GPL (GNU General Public License)
Plugin Version: 19 Apr 2006 (V1.001)
Change History:  
19 Apr 2006: Changed name of plugin (formerly OrphanFindPlugin), modified for better speed and added default, added web option
15 Apr 2006: Initial version
TWiki Dependency: $TWiki::Plugins::VERSION 1.1
CPAN Dependencies: none
Other Dependencies: none
Perl Version: 5.005
Benchmarks: Good Style 99%, Formatted Search 99%, Topic Reference Plugin 58%
Plugin Home: http://TWiki.org/cgi-bin/view/Plugins/TopicReferencePlugin
Feedback: http://TWiki.org/cgi-bin/view/Plugins/TopicReferencePluginDev
Appraisal: http://TWiki.org/cgi-bin/view/Plugins/TopicReferencePluginAppraisal

Related Topics: T Wiki Plugins, Developer Documentation Category, Admin Documentation Category, T Wiki Preferences

-- TWiki:Main.JeffCrawford - 19 Apr 2006

 
Ad Sponsor
Back to Redbourn
Copyright © We make no guarantee of the correctness of the content of this site. All material on this collaboration platform is the property of Martin Cleaver and the contributing authors.