Extension:Notificator
|
Notificator Release status: beta |
|||
|---|---|---|---|
| Implementation | Parser function, Notify, Special page, Database | ||
| Description | Notifies someone by e-mail about changes to a page when a button on that page gets clicked. | ||
| Author(s) | Patrick NagelTalk | ||
| Last version | 1.1 (2011-08-17) | ||
| MediaWiki | 1.17 beta 1 or higher | ||
| PHP | 5.2.x | ||
| Database changes | yes | ||
| License | GPL | ||
| Download |
Download snapshot (Git master)
Git [?]: repo summary • tree • code changes SVN [?]: checkout-url • tree • code changes |
||
| Example | here | ||
|
|||
|
|||
|
Check usage (experimental) |
|||
Extension:Notificator allows you to place a notification button on a page (or a set of pages, through a template). When the button is pressed, an e-mail containing the changes since the last notification, or just a link to the page if there was no notification before, is sent to an e-mail address. The e-mail address can be pre-defined, or it can be left empty, which causes the extension to show an input field next to the notification button, where any e-mail address can be entered.
The use case for which the extension was written, is the following: A company internal Wiki where task pages are work assignments, and where the project manager needs a way to notify (with the click of a button) the assigned resource about changes to the work assignments. The standard MediaWiki notification system does not work for multiple reasons:
- the assigned resource may not have all task pages on his/her watchlist
- the project manager may want to make multiple edits, and would only want to notify after all edits are done, not for each individual edit
- the project manager would want to notify one person after one edit, and another person after another edit - not everyone on every edit
There are probably other use cases where this functionality could be useful as well.
Contents |
[edit] Usage
The extension can be used in two ways:
- with a pre-set e-mail address to be notified:
{{#notificator: someone@example.com|Optional button label}} - without a pre-set e-mail address, in which case any e-mail address can be entered right on the page:
{{#notificator:}}
In most cases, one of these parser function invocations will be in a template that gets transcluded into a class of pages.
[edit] Details
When the "notify" button gets clicked, the following happens:
- Notificator checks if that e-mail address has already received a notification about the page the button is on
- If it has, Notificator checks whether the notification was for the current revision
- If it was for the current revision, it does not send another notification.
- If it was not for the current revision, it sends a mail containing a link to the page, and the differences between the current and the last notified revision
- If Notificator has never before sent a notification about this page, yet, it sends a mail containing just a link to the page
- If it has, Notificator checks whether the notification was for the current revision
The person clicking the button sees the e-mail that gets send, or a message that no notification was sent.
[edit] Known issues
- The notification e-mail is being sent in the language of the user that clicks the Notificator button - which might not be a language understood by the person being notified.
[edit] Installation
To install this extension, add the following to LocalSettings.php:
$ngFromAddress = "Notificator <notificator@example.com>"; // optional require_once("$IP/extensions/Notificator/Notificator.php");
Now please run the update.php script, which will create the necessary 'notificator' table in your Wiki's database.
[edit] Configuration parameters
[edit] $ngFromAddress
The e-mail address the notification e-mails appear to be coming from. If this is not set, $wgPasswordSender will be used instead.
[edit] Recent changes
- Version 1.1: It's now possible to notify up to 10 e-mail addresses at the same time. E-mail addresses need to be comma-separated (e.g.
{{#notificator: jane@example.com, joe@example.com|Jane and Joe}}). When updating from 1.0.x, you need to run the update.php script again.