From: Aryeh Gregor Date: Fri, 2 Jul 2010 16:42:24 +0000 (+0000) Subject: Make escapenoentities work again, broken by r68801 X-Git-Tag: 1.31.0-rc.0~36303 X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=7606490d51a594159f81bcca4ac1d9cfc5d862b8;p=lhc%2Fweb%2Fwiklou.git Make escapenoentities work again, broken by r68801 --- diff --git a/includes/Sanitizer.php b/includes/Sanitizer.php index ce508c3c20..6b1caf7cd3 100644 --- a/includes/Sanitizer.php +++ b/includes/Sanitizer.php @@ -1059,11 +1059,10 @@ class Sanitizer { * @return String: escaped input */ static function escapeHtmlAllowEntities( $html ) { + $html = Sanitizer::decodeCharReferences( $html ); # It seems wise to escape ' as well as ", as a matter of course. Can't # hurt. $html = htmlspecialchars( $html, ENT_QUOTES ); - $html = str_replace( '&', '&', $html ); - $html = Sanitizer::decodeCharReferences( $html ); return $html; }