Extension:Nominations

From MediaWiki.org
Jump to navigation Jump to search
MediaWiki extensions manual
Crystal Clear action run.svg
Nominations
Release status: beta
Implementation Notify, Parser function
Description Helps in the process of approving or rejecting nominations
Author(s) Nischay Nahata (Nischayn22talk)
Latest version 0.1 (2014-06-02)
MediaWiki 1.19+
PHP 5.3+
Database changes No
License GNU General Public License 3.0 or later
Download
README
Parameters
  • $nominationsSenderEmailAddress
Added rights
approve-nominations
Hooks used
ParserFirstCallInit
Translate the Nominations extension if it is available at translatewiki.net
Check usage and version matrix.

The Nominations extension enables you to approve or reject nominations by providing buttons that can create a new page and delete the existing page, as well send out mails to specific people or groups notifying them of this action.

A special permission "approve-nomination" is needed to perform these actions.

Installation[edit]

  • Download and place the file(s) in a directory called Nominations in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php:
    require_once "$IP/extensions/Nominations/Nominations.php";
    
  • Configure as required
  • Yes Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

Configuration[edit]

  • By default the e-mail address of the sender of nominations defaults to sender@example.com
$nominationsSenderEmailAddress = 'sender@example.com';
The e-mail provided will have to be set to a valid e-mail.
  • By default the right approve-nominations is assigned to the "sysop" user group. You can set it to another user group, preferably for a new user group:
$wgGroupPermissions['approve-nominations']['approve-nominations'] = true;

Usage[edit]

The following example text creates a button to reject a nomination:

{{#NominateAndNotify:action=reject|subject1={{{Title|}}} has been rejected|recipients1={{{Email Address|}}}|message1=Dear {{{EmailAddress|}}}, Your nomination has been approved
|create_title=Declined Nominations:{{PAGENAME}}
|create_text={{Declined Nominations|pagename={{PAGENAME}}|email={{{Email Address|}}}}}}}

On clicking the existing page will be deleted and the new page will be created with the title create_title and the content create_text. A few mails can also be sent by using the parameters subject#, message#, recipients# Where # is a number 1-6 to send up to 6 mails. Similarly one can also use action=approve, which will create a button to approve a nomination.

Authors[edit]

Nominations was originally written by Nischay Nahata, as WikiWorks consultant.