From e907ea27d0fed7199724c031a975c3d840cdbd85 Mon Sep 17 00:00:00 2001 From: Zheng Zhu Date: Wed, 22 Sep 2004 03:55:08 +0000 Subject: [PATCH] use wfMsgForContent() when creating new titles from text --- includes/Skin.php | 4 ++-- includes/Title.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/Skin.php b/includes/Skin.php index 46a9c9563c..9b40f6d303 100644 --- a/includes/Skin.php +++ b/includes/Skin.php @@ -1739,7 +1739,7 @@ class Skin { return $title->getLocalURL( $urlaction ); } /*static*/ function makeI18nUrl ( $name, $urlaction='' ) { - $title = Title::newFromText( wfMsg($name) ); + $title = Title::newFromText( wfMsgForContent($name) ); $this->checkTitle($title, $name); return $title->getLocalURL( $urlaction ); } @@ -1783,7 +1783,7 @@ class Skin { ); } /*static*/ function makeI18nUrlDetails ( $name, $urlaction='' ) { - $title = Title::newFromText( wfMsg($name) ); + $title = Title::newFromText( wfMsgForContent($name) ); $this->checkTitle($title, $name); return array( 'href' => $title->getLocalURL( $urlaction ), diff --git a/includes/Title.php b/includes/Title.php index b84f149bb7..a1b9f49b3a 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -167,7 +167,7 @@ class Title { } /* static */ function newMainPage() { - return Title::newFromText( wfMsg( 'mainpage' ) ); + return Title::newFromText( wfMsgForContent( 'mainpage' ) ); } # Get the title object for a redirect -- 2.20.1