* Restore compatibility namespace aliases for French Wikipedia
authorBrion Vibber <brion@users.mediawiki.org>
Sun, 3 Jul 2005 06:44:53 +0000 (06:44 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Sun, 3 Jul 2005 06:44:53 +0000 (06:44 +0000)
reverts change from revision 1.117

RELEASE-NOTES
languages/LanguageFr.php

index e95385b..933b3a0 100644 (file)
@@ -450,6 +450,8 @@ of MediaWiki:Newpagetext) to &action=edit, if page is new.
 * (bug 2658) Fix signature time, localtime to match timezone offset again
 * Files from shared repositories (e.g. commons) now display with their
   image description pages when viewed on local wikis.
+* Restore compatibility namespace aliases for French Wikipedia
+
 
 === Caveats ===
 
index d1d1835..ec9dbe3 100644 (file)
@@ -1360,6 +1360,20 @@ class LanguageFr extends LanguageUtf8 {
                return $wgNamespaceNamesFr;
        }
 
+
+       function getNsIndex( $text ) {
+               global $wgNamespaceNamesFr, $wgSitename;
+
+               foreach ( $wgNamespaceNamesFr as $i => $n ) {
+                       if ( 0 == strcasecmp( $n, $text ) ) { return $i; }
+               }
+               if( $wgSitename == "Wikipédia" ) {
+                       if( 0 == strcasecmp( "Wikipedia", $text ) ) return 4;
+                       if( 0 == strcasecmp( "Discussion_Wikipedia", $text ) ) return 5;
+               }
+               return false;
+       }
+
        function getQuickbarSettings() {
                global $wgQuickbarSettingsFr;
                return $wgQuickbarSettingsFr;