From 09f671770de24197338c761324a7afcc37645b1d Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Sat, 9 Dec 2006 15:32:16 +0000 Subject: [PATCH] temp hack to restore previous behaviour, re whitespace around fragments --- includes/Title.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/Title.php b/includes/Title.php index e564eb6f17..c52ea244c2 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -571,7 +571,7 @@ class Title { * Escape a text fragment, say from a link, for a URL */ static function escapeFragmentForURL( $fragment ) { - $fragment = trim( str_replace( ' ', '_', $fragment ), '_' ); + $fragment = str_replace( ' ', '_', $fragment ); $fragment = urlencode( Sanitizer::decodeCharReferences( $fragment ) ); $replaceArray = array( '%3A' => ':', @@ -1633,7 +1633,7 @@ class Title { * @access kind of public */ function setFragment( $fragment ) { - $this->mFragment = trim( str_replace( '_', ' ', substr( $fragment, 1 ) ), ' ' ); + $this->mFragment = str_replace( '_', ' ', substr( $fragment, 1 ) ); } /** -- 2.20.1