Extension:AJAX Poll

From MediaWiki.org
(Redirected from Extension:AJAXPoll)
Jump to: navigation, search
MediaWiki extensions manual - list
Crystal Clear action run.png
AJAX Poll

Release status: stable

Implementation Parser extension
Description Allows AJAX-based polls with <poll> tag
Author(s) Dariusz Siedlecki, Jack Phoenix, Thomas Gries
Last version 1.78 (2012-03-19)
MediaWiki 1.16+
trunk version works with mw trunk
Database changes php update.php
License GNU Free Documentation License [sic]
Download
Example Any ShoutWiki site
Hooks used
ParserFirstCallInit

Check usage (experimental)
Bugs: list open list all report

AJAX Poll extension allows one or more AJAX-based polls on MediaWiki pages with <poll> tag.

[edit] Installation

Note: $IP stands for the root directory of your MediaWiki installation, the same directory that holds LocalSettings.php.

  1. Download the files from SVN (or via ExtensionDistributor) and place them in $IP/extensions/AJAXPoll/
  2. on the command line run
    $IP/maintenance/php update.php
    
  3. Add to your wiki's LocalSettings.php
    require_once("$IP/extensions/AJAXPoll/AJAXPoll.php");

    # if you want to restrict the poll
    # use the following code lines after calling the AJAXPoll extension
    # to restrict to user group (example)

    # $wgGroupPermissions['*']['ajaxpoll-vote'] = false;
    # $wgGroupPermissions['user']['ajaxpoll-vote'] = true;

  4. Installation can be verified through your wiki's Special:Version.

[edit] Usage

<poll>
Do you like this poll ?
Yes, it is awesome.
Yes.
No, I do not like polls.
</poll>

20120216 AJAX Poll screenshot.png

If the first line after <poll> is "STATS", then some statistics about the wiki and its polls will be displayed. These statistics are not localizable and this whole feature will probably be removed (or at least refactored, but probably removed) in the future.

[edit] To-do list

  1. List of open bugs
  2. add/implement options
    1. bug 35118 option to allow only users with edit rights to vote, or only logged-in user implemented in version 1.63 (r113355)
    2. bug 35119 AJAXPoll: add option to show poll results only for users who have voted}}
    3. bug 35120 AJAXPoll as simple ranking tool (add a different skin for poll vote and result layout)
  3. a new permission / user rights group for a new Special page for Poll maintenance (list, stop, delete polls)
Personal tools
Namespaces

Variants
Actions
Navigation
Support
Download
Development
Communication
Print/export
Toolbox