Highscores Action Documentation

This the documentation page for the {{highscores}} action.

Documentation


Displays a list of top contributors. Since 1.1.6.4 contributors can be ranked by different metrics: number of pages owned, edits or comments.

Long description
This action displays a table with users ranked after the quantity of their contributions to the wiki. After the username, the number of contributions and their percentage over the whole wiki is displayed.

Usage:
{{highscores [top="20"] [rank="edits"] [style="complex"]}}

Parameters

since 1.1.6.4

Parameters
nametyperequired?defaultdescription
topintoptional10the number of rows to be displayed
rankstringoptionalpagesselect the metric used to rank contributors (pages, edits, comments)
stylestringoptionalcomplexdisplays a simple table (simple) or a table with caption and headers (complex)

Examples:

{{highscores}}

Top 6 contributor(s)
rank user pages owned percentage
1.  BrianKoontz 68 16.3%
2.  DarTar 65 15.6%
3.  YanB 45 10.8%
4.  VincentMayoux 37 8.9%
5.  NilsLindenberg 5 1.2%
6.  ThePLG 4 1%


{{highscores style="simple"}}

1.  BrianKoontz 68 16.3%
2.  DarTar 65 15.6%
3.  YanB 45 10.8%
4.  VincentMayoux 37 8.9%
5.  NilsLindenberg 5 1.2%
6.  ThePLG 4 1%


{{highscores rank="edits"}}

Top 10 contributor(s)
rank user edits percentage
1.  DarTar 880 35.1%
2.  BrianKoontz 584 23.3%
3.  YanB 374 14.9%
4.  VincentMayoux 320 12.8%
5.  NilsLindenberg 159 6.3%
6.  WikkaInstaller 46 1.8%
7.  ThePLG 29 1.2%
8.  DotMG 25 1%
9.  JavaWoman 19 0.8%
10.  TormodHaugen 7 0.3%


{{highscores rank="edits" top="3"}}

Top 3 contributor(s)
rank user edits percentage
1.  DarTar 880 35.1%
2.  BrianKoontz 584 23.3%
3.  YanB 374 14.9%





Authors
Chriss Tessmer
Dario Taraborelli


CategoryEN
Comments
Comment by anonymous
2008-06-04 08:35:16
The action does not accept any parameters? That's quite outdated, isn't it ;-).
Comment by DarTar
2008-06-04 09:26:55
fixed, thanks!
Comment by anonymous
2008-09-11 20:19:59
Seems like the current code (as of today) is busted for the rank parameter. It looks like it was hardcoded to $pages at the top of highscores.php, and never altered after that. Removing the $rank = 'pages' hardcoding, and adding the below worked:
%%
if (!isset($rank) || !in_array($rank, $valid_rank))
{
$rank = 'pages';
}
%%
Comment by DotMG
2008-09-12 04:46:44
fixed in trunk. To be backported to 1.1.6.6
Comment by anonymous
2008-09-12 17:24:11
ok. looked for a bug, but didn't find one. sorry for the noise.
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki