r16853 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r16852‎ | r16853 | r16854 >
Date:06:40, 8 October 2006
Author:rotem
Status:old
Tags:
Comment:
Fixes for the translation statistics script - HTML, organisation, etc.
Modified paths:
  • /trunk/phase3/maintenance/language/transstat.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/language/transstat.php
@@ -18,6 +18,7 @@
1919 if ( isset( $options['help'] ) ) {
2020 showUsage();
2121 }
 22+
2223 # Default output is WikiText
2324 if ( !isset( $options['output'] ) ) {
2425 $options['output'] = 'wiki';
@@ -63,10 +64,10 @@
6465 function heading() {
6566 global $IP;
6667 $version = SpecialVersion::getVersion( $IP );
67 - echo "'''Statistics based on:''' <tt>" . $version . "</tt>\n\n";
 68+ echo "'''Statistics are based on:''' <code>" . $version . "</code>\n\n";
6869 echo "'''Note:''' These statistics can be generated by running <code>php maintenance/language/transstat.php</code>.\n\n";
6970 echo "For additional information on specific languages (the message names, the actual problems, etc.), run <code>php maintenance/language/checkLanguage.php --lang=foo</code>.\n\n";
70 - echo "{| border=2 cellpadding=4 cellspacing=0 style=\"background: #f9f9f9; border: 1px #aaa solid; border-collapse: collapse;\" width=100%\n";
 71+ echo '{| border="2" cellpadding="4" cellspacing="0" style="background-color: #F9F9F9; border: 1px #AAAAAA solid; border-collapse: collapse;" width="100%"'."\n";
7172 }
7273 function footer() {
7374 echo "|}\n";
@@ -104,9 +105,13 @@
105106
106107 /** Outputs WikiText and appends category only used for Meta-Wiki */
107108 class metawikiStatsOutput extends wikiStatsOutput {
 109+ function header() {
 110+ echo "See [[MediaWiki localisation]] to learn how you can help translating MediaWiki.\n";
 111+ parent::header();
 112+ }
108113 function footer() {
109 - echo "|}\n\n";
110 - echo "[[Category:Localisation|Statistics]]\n";
 114+ parent::footer();
 115+ echo "\n[[Category:Localisation|Statistics]]\n";
111116 }
112117 }
113118