r68891 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r68890‎ | r68891 | r68892 >
Date:16:42, 2 July 2010
Author:simetrical
Status:ok
Tags:
Comment:
Make escapenoentities work again, broken by r68801
Modified paths:
  • /trunk/phase3/includes/Sanitizer.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Sanitizer.php
@@ -1059,11 +1059,10 @@
10601060 * @return String: escaped input
10611061 */
10621062 static function escapeHtmlAllowEntities( $html ) {
 1063+ $html = Sanitizer::decodeCharReferences( $html );
10631064 # It seems wise to escape ' as well as ", as a matter of course. Can't
10641065 # hurt.
10651066 $html = htmlspecialchars( $html, ENT_QUOTES );
1066 - $html = str_replace( '&', '&', $html );
1067 - $html = Sanitizer::decodeCharReferences( $html );
10681067 return $html;
10691068 }
10701069

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r68801When using escapenoentities, decode entities...simetrical23:08, 30 June 2010

Status & tagging log