Index: trunk/extensions/UserOptionStats/UserOptionStats.alias.php |
— | — | @@ -12,4 +12,4 @@ |
13 | 13 | */ |
14 | 14 | $aliases['en'] = array( |
15 | 15 | 'UserOptionStats' => array( 'UserOptionStats' ), |
16 | | -); |
\ No newline at end of file |
| 16 | +); |
Index: trunk/extensions/UserOptionStats/UserOptionStats.i18n.php |
— | — | @@ -12,9 +12,10 @@ |
13 | 13 | */ |
14 | 14 | $messages['en'] = array( |
15 | 15 | 'useroptionstats' => 'User option statistics', |
| 16 | + 'useroptionstats-desc' => '[[Special:UserOptionStats|Special page]] for reporting on Mediawiki user option usage', |
16 | 17 | 'uos-warn' => 'PHPlot is not installed!', |
17 | 18 | 'uos-choose' => 'Choose one of the following user options: $1', |
18 | 19 | 'uos-unknown' => '*Default', |
19 | 20 | 'uos-other' => '*Other', |
20 | 21 | 'uos-title' => 'Distribution of values of user option $1', |
21 | | -); |
\ No newline at end of file |
| 22 | +); |
Index: trunk/extensions/UserOptionStats/UserOptionStats.php |
— | — | @@ -6,7 +6,7 @@ |
7 | 7 | * Requirements: PHPlot and FCFontFinder (for i18n fonts, optional). |
8 | 8 | * FCFontFinder can be found with extension Translate at utils/Font.php. |
9 | 9 | * Also need to install fonts for all languages! |
10 | | - * |
| 10 | + * |
11 | 11 | * PHPlot needs to be in $wgAutoloadClasses: |
12 | 12 | * $wgAutoloadClasses['PHPlot'] = '/path/to/phplot/phplot.php' |
13 | 13 | * |
— | — | @@ -23,9 +23,19 @@ |
24 | 24 | * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later |
25 | 25 | */ |
26 | 26 | |
| 27 | +$wgExtensionCredits['specialpage'][] = array( |
| 28 | + 'path' => __FILE__, |
| 29 | + 'name' => 'User Option Statistics', |
| 30 | + 'version' => '1.0', |
| 31 | + 'author' => 'Niklas Laxström', |
| 32 | + 'description' => '[[Special:UserOptionStats|Special page]] for reporting on Mediawiki user option usage', |
| 33 | + 'descriptionmsg' => 'useroptionstats-desc', |
| 34 | + 'url' => 'http://www.mediawiki.org/wiki/Extension:UserOptionStats', |
| 35 | +); |
| 36 | + |
27 | 37 | $dir = dirname( __FILE__ ); |
28 | 38 | $wgAutoloadClasses['SpecialUserOptionStats'] = "$dir/SpecialUserOptionStats.php"; |
29 | 39 | $wgExtensionMessagesFiles['UserOptionStats'] = "$dir/UserOptionStats.i18n.php"; |
30 | 40 | $wgExtensionAliasesFiles['UserOptionStats'] = "$dir/UserOptionStats.alias.php"; |
31 | 41 | $wgSpecialPages['UserOptionStats'] = 'SpecialUserOptionStats'; |
32 | | -$wgSpecialPageGroups['UserOptionStats'] = 'wiki'; |
\ No newline at end of file |
| 42 | +$wgSpecialPageGroups['UserOptionStats'] = 'wiki'; |
Index: trunk/extensions/UserOptionStats/SpecialUserOptionStats.php |
— | — | @@ -16,7 +16,6 @@ |
17 | 17 | } |
18 | 18 | |
19 | 19 | public $blacklist = array( 'nickname' ); |
20 | | - |
21 | 20 | |
22 | 21 | public function execute( $par ) { |
23 | 22 | global $wgRequest, $wgUser, $wgOut, $wgLang, $wgAutoloadClasses; |
— | — | @@ -46,9 +45,6 @@ |
47 | 46 | return; |
48 | 47 | } |
49 | 48 | |
50 | | - |
51 | | - |
52 | | - |
53 | 49 | $dbr = wfGetDB( DB_SLAVE ); |
54 | 50 | |
55 | 51 | $users = $dbr->select( 'user', '*', '', __METHOD__ ); |
— | — | @@ -118,7 +114,7 @@ |
119 | 115 | |
120 | 116 | public function getOptions() { |
121 | 117 | global $wgDefaultUserOptions; |
122 | | - |
| 118 | + |
123 | 119 | $opts = array(); |
124 | 120 | foreach ( $wgDefaultUserOptions as $k => $v ) $opts[$k] = true; |
125 | 121 | |
Index: trunk/extensions/Translate/groups/mediawiki-defines.txt |
— | — | @@ -941,6 +941,8 @@ |
942 | 942 | |
943 | 943 | User Merge |
944 | 944 | |
| 945 | +User Option Stats |
| 946 | + |
945 | 947 | User Rights Notification |
946 | 948 | id = ext-userrightsnotif |
947 | 949 | file = UserRightsNotif/UserRightsNotif.i18n.php |
Index: trunk/extensions/Translate/aliases.txt |
— | — | @@ -286,6 +286,9 @@ |
287 | 287 | User merge |
288 | 288 | file = UserMerge/UserMerge.alias.php |
289 | 289 | |
| 290 | +User option stats |
| 291 | +file = UserOptionStats/UserOptionStats.alias.php |
| 292 | + |
290 | 293 | Vote |
291 | 294 | file = Vote/Vote.alias.php |
292 | 295 | |