Subscribe Add-On

This add-on adds a "Subscribe Topic" button next to the Edit, Attach, Printable buttons. When clicked it will add a user and the topic to the WebNotify topic. The MailerContrib system reads the WebNotify topic and sends a mail if the specified topic changes.

The Subscribe add-on is based on PerTopicNotificationAddOn.

Usage

  • Log in.
  • Click on the "Subscribe Topic" button to add the current topic to the Notification list.

Function

The Subscribe Add-on will make changes to WebNotify based on the following decisions:

  • User is not in WebNotify: --> Add ' * User: + Topic' to WebNotify.
  • User is in WebNotify:
    • User gets notified for specified topics:
      • If the topic is not already in the list: --> Add ' + Topic' to the users line in WebNotify.
      • If the topic is already in the list: --> Do nothing.
    • User gets notified for whole web: --> Do nothing.
    • User gets notified for whole web but exclude some topics:
      • If the topic is excluded from notification: --> Remove ' - Topic' from the users line in WebNotify.
      • If the topic is not excluded: --> Do nothing.

Permission

You have to log in to subscribe a topic to WebNotify. Furthermore you need permission to read the web.topic you want to add to the notification list and to change WebNotify. Subscribe Add-on will check the permissions to prevent unauthorized users to get onto the WebNotity topic.

Add-On Installation Instructions

Note: You do not need to install anything on the browser to use this add-on. The following instructions are for the administrator who installs the add-on on the server where TWiki is running.

  • Download the ZIP file from the Add-on Home (see below)
  • Unzip SubscribeAddOn.zip in your twiki installation directory. Content:

File: Description:
data/TWiki/SubscribeAddOn.txt Add-on topic
data/TWiki/SubscribeAddOn.txt,v Add-on topic repository
bin/subscribe Add-on script
lib/TWiki/Contrib/Subscribe.pm Add-on perl package
templates/oopsnotify.tmpl Template
templates/view.pattern.tmpl.example "Subscribe Topic" button definition
gpl.txt GPL

  • Correct the permissions and ownership.
  • Add the contents of templates/view.pattern.tmpl.example to templates/view.pattern.tmpl
  • Add the button to the toolbar in templates/viewtoolbar.pattern.tmpl . Put the following at the end of the line defining the buttons: <span class="patternButton">%TMPL:P{"subscribe"}%</span>
  • Remove notification lines except TWikiGuest from WebNotify to get a fresh start.
    TWikiGuest is needed to know where to add a new notification line.
  • Test if the installation was successful:
    • Log in, go to some topic, click on the "Subscribe Topic" button.
    • Go to the WebNotify topic and look for your WikiName and topic.
    • If not successful set $debug = 1 in Subscribe.pm and read data/debug.txt for hints what the problem is.

Add-On Info

  • Set SHORTDESCRIPTION = Provides a "Subscribe Topic" button to add topic to WebNotify.

Add-on Author: TWiki:Main/MarkusBajones
Add-on Version: 26 Oct 2006 (v1.10)
Change History:  
03 Sep 2006: Initial version
26 Oct 2006 v1.10
CPAN Dependencies: none
Other Dependencies: MailerContrib
Perl Version: 5.005
License: GPL
Add-on Home: http://TWiki.org/cgi-bin/view/Plugins/SubscribeAddOn
Feedback: http://TWiki.org/cgi-bin/view/Plugins/SubscribeAddOnDev
Appraisal: http://TWiki.org/cgi-bin/view/Plugins/SubscribeAddOnAppraisal

Related Topic: TWikiAddOns

-- TWiki:Main/MarkusBajones - 03 Sep 2006

Topic attachments
I Attachment History Action Size Date Who Comment
Compressed Zip archivezip SubscribeAddOn.zip r2 r1 manage 21.7 K 2006-10-26 - 12:27 UnknownUser Updated the script according to SubscribeAddOnDev.
Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r3 - 2006-10-26 - MarkusBajones
 
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.