From: Bryan Tong Minh Date: Sat, 5 Apr 2008 14:57:41 +0000 (+0000) Subject: (bug 13616) Replace underscores in search terms by spaces X-Git-Tag: 1.31.0-rc.0~48609 X-Git-Url: http://git.cyclocoop.org/%22.%24h.%22?a=commitdiff_plain;h=43dfeea8b1024184fbd7a85e9770e28a9697aa06;p=lhc%2Fweb%2Fwiklou.git (bug 13616) Replace underscores in search terms by spaces --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index beedfaa6d8..ff2ea0782d 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -151,6 +151,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 13576) maintenance/rebuildrecentchanges.php fails * (bug 13441) Allow Special:Recentchanges to show bots only * (bug 13431) Show true message source in Special:Allmessages&ot=php / xml +* (bug 13616) Replace underscores in search terms by spaces === API changes in 1.13 === diff --git a/includes/SpecialSearch.php b/includes/SpecialSearch.php index 84d1568a7d..e41bff511a 100644 --- a/includes/SpecialSearch.php +++ b/includes/SpecialSearch.php @@ -30,7 +30,8 @@ function wfSpecialSearch( $par = '' ) { global $wgRequest, $wgUser; - $search = str_replace( "\n", " ", $wgRequest->getText( 'search', $par ) ); + $search = str_replace( array('_', "\n"), " ", + $wgRequest->getText( 'search', $par ) ); $searchPage = new SpecialSearch( $wgRequest, $wgUser ); if( $wgRequest->getVal( 'fulltext' ) || !is_null( $wgRequest->getVal( 'offset' ) ) ||