dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e186e69
)
Fix hardcoded path to the languages directory
author
Antoine Musso
<hashar@users.mediawiki.org>
Wed, 6 Jul 2005 22:34:09 +0000
(22:34 +0000)
committer
Antoine Musso
<hashar@users.mediawiki.org>
Wed, 6 Jul 2005 22:34:09 +0000
(22:34 +0000)
maintenance/transstat.php
patch
|
blob
|
history
diff --git
a/maintenance/transstat.php
b/maintenance/transstat.php
index
fe338b1
..
f8aac37
100644
(file)
--- a/
maintenance/transstat.php
+++ b/
maintenance/transstat.php
@@
-5,10
+5,16
@@
*
* @author Ævar Arnfjörð Bjarmason <avarab@gmail.com>
* @bug 2499
*
* @author Ævar Arnfjörð Bjarmason <avarab@gmail.com>
* @bug 2499
+ *
+ * Output is posted from time to time on:
+ * http://meta.wikimedia.org/wiki/Localization_statistics
*/
*/
+/** */
+require_once('commandLine.inc');
+
$langs = array();
$langs = array();
-$dir = opendir(
'languages'
);
+$dir = opendir(
"$IP/languages"
);
while ($file = readdir($dir)) {
if (preg_match("/Language(.*?)\.php$/", $file, $m)) {
$langs[] = $m[1];
while ($file = readdir($dir)) {
if (preg_match("/Language(.*?)\.php$/", $file, $m)) {
$langs[] = $m[1];
@@
-23,7
+29,6
@@
foreach($langs as $key => $lang) {
unset($langs[$key]);
}
unset($langs[$key]);
}
-require_once('commandLine.inc');
$msgs = array();
foreach($langs as $lang) {
$msgs = array();
foreach($langs as $lang) {
@@
-43,6
+48,7
@@
foreach($langs as $lang) {
}
}
}
}
+// wiki syntax header
$out = "{| border=2 cellpadding=4 cellspacing=0 style=\"background: #f9f9f9; border: 1px #aaa solid; border-collapse: collapse;\" width=100%\n";
$out .= beginul();
$out .= li('Language', true);
$out = "{| border=2 cellpadding=4 cellspacing=0 style=\"background: #f9f9f9; border: 1px #aaa solid; border-collapse: collapse;\" width=100%\n";
$out .= beginul();
$out .= li('Language', true);
@@
-53,6
+59,8
@@
$out .= li('%', true);
$out .= li('Redundant', true);
$out .= li('%', true);
$out .= endul();
$out .= li('Redundant', true);
$out .= li('%', true);
$out .= endul();
+
+// generate table rows using wikisyntax
foreach($msgs as $lang => $stats) {
$out .= beginul();
$out .= li($wgContLang->getLanguageName(strtr($lang, '_', '-')) . " ($lang)"); // Language
foreach($msgs as $lang => $stats) {
$out .= beginul();
$out .= li($wgContLang->getLanguageName(strtr($lang, '_', '-')) . " ($lang)"); // Language