Extension:DownloadCounter

From MediaWiki.org
Jump to navigation Jump to search
MediaWiki extensions manual
OOjs UI icon advanced.svg
DownloadCounter
Release status: unmaintained
Implementation Tag
Description Add some functions for counting user's downloaded file(s)
Author(s) Eric Petit (Surfzoidtalk)
Latest version 0.4.0 (2014-05-09)
MediaWiki 1.11+
Database changes Yes
License GNU General Public License 2.0 or later
Download
Translate the DownloadCounter extension if it is available at translatewiki.net
Check usage and version matrix.

The DownloadCounter extension can display the total number and the last date of downloaded files, which are recorded in the MySQL database.

Installation[edit]

  • Download and place the file(s) in a directory called DownloadCounter in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php:
    require_once "$IP/extensions/DownloadCounter/DownloadCounter.php";
    
  • Run the update script which will automatically create the necessary database tables that this extension needs.
  • Yes Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.
Warning Warning: Older versions of this extension had security issues. Use at least 0.4.0

Usage[edit]

On your wiki page, you will setup an download like this:

[http://exemple.com/mediawiki/download.php?f=Setup-DataCollectorEdit.2.0.exe Download this great software here]

And display the recorded data like that:

<DownloadCounter name="Setup-DataCollectorEdit.2.0.exe" type="total"></DownloadCounter> total download.
 Last download was: <DownloadCounter name="Setup-DataCollectorEdit.2.0.exe" type="date"></DownloadCounter>