From dac2ca94f4e408fa951a490d3fb759daec961d7b Mon Sep 17 00:00:00 2001 From: Jens Frank Date: Sat, 28 Aug 2004 19:08:49 +0000 Subject: [PATCH] BUG#160 Internationalize display of numbers: * section numbers in TOC * file size in edit page warning for big articles. --- includes/EditPage.php | 2 +- includes/Parser.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/EditPage.php b/includes/EditPage.php index d1c3a9f627..83f3034637 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -290,7 +290,7 @@ class EditPage { $kblength = (int)(strlen( $this->textbox1 ) / 1024); if( $kblength > 29 ) { $wgOut->addHTML( '' . - wfMsg( 'longpagewarning', $kblength ) + wfMsg( 'longpagewarning', $wgLang->formatNum( $kblength ) ) . '' ); } diff --git a/includes/Parser.php b/includes/Parser.php index ae665d2fd3..4a1bc0c70c 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -1855,7 +1855,7 @@ class Parser # It loops through all headlines, collects the necessary data, then splits up the # string and re-inserts the newly formatted headlines. /* private */ function formatHeadings( $text, $isMain=true ) { - global $wgInputEncoding, $wgMaxTocLevel; + global $wgInputEncoding, $wgMaxTocLevel, $wgLang; $doNumberHeadings = $this->mOptions->getNumberHeadings(); $doShowToc = $this->mOptions->getShowToc(); @@ -1954,7 +1954,7 @@ class Parser if( $dot ) { $numbering .= '.'; } - $numbering .= $sublevelCount[$i]; + $numbering .= $wgLang->formatNum( $sublevelCount[$i] ); $dot = 1; } } -- 2.20.1