r84054 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r84053‎ | r84054 | r84055 >
Date:20:30, 15 March 2011
Author:yaron
Status:ok
Tags:
Comment:
Added escaping so that a search string containing a space can be used on page names
Modified paths:
  • /trunk/extensions/ReplaceText/SpecialReplaceText.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ReplaceText/SpecialReplaceText.php
@@ -511,6 +511,8 @@
512512
513513 $tables = array( 'page' );
514514 $vars = array( 'page_title', 'page_namespace' );
 515+
 516+ $str = str_replace( ' ', '_', $str );
515517 if ( $use_regex ) {
516518 $comparisonCond = 'page_title REGEXP ' . $dbr->addQuotes( $str );
517519 } else {

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r82212Added handling for regular expressionsyaron03:11, 16 February 2011

Status & tagging log