From: Timo Tijhof Date: Mon, 14 Jan 2013 21:43:02 +0000 (+0100) Subject: SpecialEditWatchlist: Don't re-escape html option values. X-Git-Tag: 1.31.0-rc.0~21038^2 X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=8e503c74848f6e64105dfdd464352d4c55376d2f;p=lhc%2Fweb%2Fwiklou.git SpecialEditWatchlist: Don't re-escape html option values. HTMLForm class already escapes them. The values here should be actual values that can be used directly internally without any sort of encoding or escaping. It was working fine because HTMLForm used this array two-way, so it was also checking against the "wrong" values upon submission. For the same reason, removing it here will not affect anything. It does however fix the problem where it is hard to filter these options in javascript because the values don't match. Change-Id: Ieb0d4955febaccda2bdca58b316883337831ebfa --- diff --git a/includes/specials/SpecialEditWatchlist.php b/includes/specials/SpecialEditWatchlist.php index eca62f2e87..ae7657cf1c 100644 --- a/includes/specials/SpecialEditWatchlist.php +++ b/includes/specials/SpecialEditWatchlist.php @@ -489,7 +489,7 @@ class SpecialEditWatchlist extends UnlistedSpecialPage { $title = Title::makeTitleSafe( $namespace, $dbkey ); if ( $this->checkTitle( $title, $namespace, $dbkey ) ) { $text = $this->buildRemoveLine( $title ); - $fields['TitlesNs'.$namespace]['options'][$text] = htmlspecialchars( $title->getPrefixedText() ); + $fields['TitlesNs'.$namespace]['options'][$text] = $title->getPrefixedText(); $count++; } }