From MediaWiki.org
Jump to: navigation, search
MediaWiki extensions manual
Crystal Clear app error.png
Top Ten Pages

Release status: unstable

Implementation Tag, User activity, Special page
Description Allows to display the most popular pages of a wiki on a page
Author(s) Saschatalk
Latest version 0.3.2 (2014-06-25)
MediaWiki 1.19-1.24 (underlying function removed in 1.25+)
PHP 5.3+
Database changes No
License No license specified
Download see here

$wgttpAlwaysStartAtOne <TopTenPages/> or

<TopTenPages offset="1">5</TopTenPages>

Translate the TopTenPages extension if it is available at translatewiki.net

Check usage and version matrix; code metrics

The TopTenPages extension allows to display the most popular pages of the wiki on a page.

Usage[edit | edit source]

 <TopTenPages [offset=OFFSET]>[NUMBEROFPAGES]</TopTenPages>


Format: Number
Default: 0 or -
How many of the most popular Pages to ignore. (e.g. 1 to ignore the main page)
Format: Number
Default: 10
Maximum number of pages to be listed.

Examples[edit | edit source]

To show 10 most popular Pages:


To show 5 most popular Pages:


To omit the most popular page(s):

<TopTenPages offset=1/> 

This Extension makes use of the Wiki-Builtin-Function Special:Popularpages with similar functionality (which is disabled in some installations).

Image description[edit | edit source]

The Image was created by this code:

==Most visited pages==
[[Special:PopularPages|mehr >>]]

Installation[edit | edit source]

Copy Code files to your extensions directory.

To install the extension, add to your LocalSettings.php:


Configuration[edit | edit source]

By default, if the offset is set, the numbering will start based on the offset. If you specifiy offset=1 as in the example above your list will start with 2. ie. "2 The art of cooking" instead of "1 The art of cooking". This is probably not the desired behavior. Set this variable to true to avoid this.
$wgttpAlwaysStartAtOne = true;

Sites that use TopTenPages[edit | edit source]