r1 - 10 Feb 2008 - 16:45:42 - TWikiGuestYou are here: WikiGardens.com >  TWiki Web > SubscribePlugin

Subscribe Plugin

This is a companion plugin to the MailerContrib. It allows you to trivially add a "Subscribe me" link to topics to get subscribed to changes.

Example (only works if plugin is installed, and you are logged in (not TWikiGuest)):

Usage

Anywhere in a topic or template:

  • %SUBSCRIBE{...}% or simply %SUBSCRIBE%
Parameter Default Meaning
who Logged-in user Who to subscribe (wikiname, no web)
topic Current topic Topic to subscribe to. Wildcards may be used e.g. topic="Item*" will subscribe to all topics starting with Item. Use topic="Main.*" to subscribe to the WebNotify for that web.
unsubscribe Not set If set to "on", will unsubscribe the user
format Simple HTML Link with an action anchor "Subscribe" or "Unsubscribe" Defines custom look-and-feel for subscribe link using the following format variables: $topics, $url, $wikiname, $action
formatunsubscribe format Serves same function as format, but allows the user to define a different format than subscribe.

  • The button toggles subscribe/unsubscribe if the user is already subscribed or vice versa. So after the next click on the button, the user will be unsubscribed.
  • The plugin will do the best it can to optimise the subscription lists in WebNotify.
  • Subscription events will return to the topic originally being viewed.

Access Controls

The guest user is not allowed to subscribe for notification.

You don't need VIEW access to the WebNotify topic in order to subscribe to changes in a web, but you must have CHANGE access. If you want users to be able to subscribe or unsubscribe, but you don't want them to be able to modify their subscription or otherwise edit the WebNotify topic, you can restrict VIEW access to WebNotify. This will make it uneditable from the browser (but will not block save urls, so is not fully secure).

ALERT! Note that permissions on individual topics are not checked when subscription mails are sent out, so be very careful about who you allow to subscribe.

Plugin 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 where TWiki is running.

Like many other TWiki extensions, this module is shipped with a fully automatic installer script written using the BuildContrib.

  • If you have TWiki 4.1 or later, you can install from the configure interface (Go to Plugins->Find More Extensions)
    • The webserver user has to have permission to write to all areas of your installation for this to work.
  • If you have a permanent connection to the internet, you are recommended to use the automatic installer script
    • Just download the SubscribePlugin_installer perl script and run it.
  • Notes:
    • The installer script will:
      • Automatically resolve dependencies,
      • Copy files into the right places in your local install (even if you have renamed data directories),
      • check in new versions of any installed files that have existing RCS histories files in your existing install (such as topics).
      • If the $TWIKI_PACKAGES environment variable is set to point to a directory, the installer will try to get archives from there. Otherwise it will try to download from twiki.org or cpan.org, as appropriate.
      • (Developers only: the script will look for twikiplugins/SubscribePlugin/SubscribePlugin.tgz before downloading from TWiki.org)
    • If you don't have a permanent connection, you can still use the automatic installer, by downloading all required TWiki archives to a local directory.
      • Point the environment variable $TWIKI_PACKAGES to this directory, and the installer script will look there first for required TWiki packages.
        • $TWIKI_PACKAGES is actually a path; you can list several directories separated by :
      • If you are behind a firewall that blocks access to CPAN, you can pre-install the required CPAN libraries, as described at http://twiki.org/cgi-bin/view/TWiki/HowToInstallCpanModules
  • If you don't want to use the installer script, or have problems on your platform (e.g. you don't have Perl 5.8), then you can still install manually:
    1. Download and unpack one of the .zip or .tgz archives to a temporary directory.
    2. Manually copy the contents across to the relevant places in your TWiki installation.
    3. Check in any installed files that have existing ,v files in your existing install (take care not to lock the files when you check in)
    4. Manually edit LocalSite.cfg to set any configuration variables.
    5. Run configure and enable the module, if it is a plugin.
    6. Repeat from step 1 for any missing dependencies.

Plugin Info

This plugin is brought to you by the WikiRing - working together to improve your wiki experience!

Plugin Author: TWiki:Main.CrawfordCurrie
Copyright: © 2007, Crawford Currie http://c-dot.co.uk
License: GPL (GNU General Public License)
Plugin Version: 14404 (14 Jul 2007)
Dependencies:
NameVersionDescription
TWiki::Contrib::MailerContrib>=13511TWiki 4 mailer module
Change History:  
13966 Bugs:Item4155 Fixed for 4.0.x and 4.1.x
13787 Item4010fix web subscription, and format parameters. - TWiki:Main.SvenDowideit
13525 Item3731 Update documentation topic.
13512 Item3731 final pre-release tweaks, result of testing on 4.1.2
13510 Item3731 completed the plugin now that the Mailer updates are done
13506 Item3731 Update dependency to latest version of MailerContrib
13081 Item3731 Added SubscribePlugin, and cleaned up and updated APIs in MailerContrib
?1' '  
24 Apr 2007 First version
Plugin Home: http://TWiki.org/cgi-bin/view/Plugins/SubscribePlugin
Feedback: http://TWiki.org/cgi-bin/view/Plugins/SubscribePluginDev
Appraisal: http://TWiki.org/cgi-bin/view/Plugins/SubscribePluginAppraisal

Related Topics: TWikiPlugins, DeveloperDocumentationCategory, AdminDocumentationCategory, TWikiPreferences

Creative Commons License This site is powered by the TWiki collaboration platformUnless otherwise noted, all content on this site is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License.
Ideas, requests, problems regarding WikiGardens.com? Send feedback
Note: Please contribute updates to this topic on TWiki.org at TWiki:TWiki.SubscribePlugin
 

“When a good wind blows be ready to sail.”
~ Claire Lynch