Extension:ArticleRatings

From MediaWiki.org
Jump to: navigation, search
MediaWiki extensions manual - list
Crystal Clear action run.png
ArticleRatings

Release status: stable

ArticleRatings.png
Implementation Tag, Special page
Description Adds a complex interface for giving pages ratings.
Author(s) Adam Carter (UltrasonicNXTtalk)
Last version 1.0.1 (29/07/12)
MediaWiki Should work on 1.17 or above, may work below that, but targeted for 1.19
PHP Any fairly decent version
License GPL
Download http://adams-site.x10.mx/ARE.html
http://adams-site.x10.mx/README
Parameters

None, but if you need them, contact me and I'll add them.

Tags
<rating />
Added rights

changeRating

Hooks used
ParserFirstCallInit
Check usage and version matrix

The ArticleRatings extension adds an interface for rating pages.

This extension was developed for Brickipedia, and is not as portable as it could be. If you need to use it on a separate MediaWiki installation, please don't hesitate to contact me on my Wikia talk page.

Contents

Installation [edit]

  • Download and extract the files in a directory called "ArticleRatings" in your extensions/ folder.
  • Add the following code to your LocalSettings.php (at the bottom)
require_once( "$IP/extensions/ArticleRatings/ArticleRatings.php" );
  • Yes check.svg Done – Navigate to "Special:Version" on your wiki to verify that the extension is successfully installed.

Configuration parameters [edit]

User rights [edit]

  • changeRating - new user right allows user to change the ratings of pages.

Tags [edit]

<rating /> adds the rating of a page to a page. <rating /> on it's own will add the rating of the page it is on, and <rating page="title" /> will give the rating of title.

Special Pages [edit]

  • Special:ChangeRating - interface for changing pages' ratings.
  • Special:MassRatings - interface for getting the ratings of many pages at once.

Messages [edit]

  • MediaWiki:Ratings - JSON file giving the name, codename (has to be 2 characters long), image, and link, for each rating. Should be an array of objects, in PHP-valid JSON.
  • MediaWiki:Rating-default - the codename of the rating that should be give to pages that have not yet had their rating changed.
  • MediaWiki:Rating-box - tells how the rating should be formatted when given by <rating />. Has four parameters: $1=The rating's image, $2=rating name $3=link to change the rating, $4="Rating for:" prefix given when rating acquired by <rating page="title" />.