Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -628,7 +628,9 @@ |
629 | 629 | if ( in_array('escape', $options) ) { |
630 | 630 | $string = htmlspecialchars ( $string ); |
631 | 631 | } elseif ( in_array( 'escapenoentities', $options ) ) { |
632 | | - $string = Sanitizer::escapeHtmlAllowEntities( $string ); |
| 632 | + $string = htmlspecialchars( $string ); |
| 633 | + $string = str_replace( '&', '&', $string ); |
| 634 | + $string = Sanitizer::normalizeCharReferences( $string ); |
633 | 635 | } |
634 | 636 | |
635 | 637 | if( in_array('replaceafter', $options) ) { |
Index: trunk/phase3/includes/Linker.php |
— | — | @@ -1046,8 +1046,7 @@ |
1047 | 1047 | |
1048 | 1048 | # Sanitize text a bit: |
1049 | 1049 | $comment = str_replace( "\n", " ", $comment ); |
1050 | | - # Allow HTML entities (for bug 13815) |
1051 | | - $comment = Sanitizer::escapeHtmlAllowEntities( $comment ); |
| 1050 | + $comment = htmlspecialchars( $comment ); |
1052 | 1051 | |
1053 | 1052 | # Render autocomments and make links: |
1054 | 1053 | $comment = $this->formatAutoComments( $comment, $title, $local ); |
Index: trunk/phase3/includes/Sanitizer.php |
— | — | @@ -827,22 +827,6 @@ |
828 | 828 | } |
829 | 829 | |
830 | 830 | /** |
831 | | - * Given HTML input, escape with htmlspecialchars but un-escape entites. |
832 | | - * This allows (generally harmless) entities like to survive. |
833 | | - * |
834 | | - * @param string $html String to escape |
835 | | - * @return string Escaped input |
836 | | - */ |
837 | | - static function escapeHtmlAllowEntities( $html ) { |
838 | | - # It seems wise to escape ' as well as ", as a matter of course. Can't |
839 | | - # hurt. |
840 | | - $html = htmlspecialchars( $html, ENT_QUOTES ); |
841 | | - $html = str_replace( '&', '&', $html ); |
842 | | - $html = Sanitizer::normalizeCharReferences( $html ); |
843 | | - return $html; |
844 | | - } |
845 | | - |
846 | | - /** |
847 | 831 | * Regex replace callback for armoring links against further processing. |
848 | 832 | * @param array $matches |
849 | 833 | * @return string |
Index: trunk/phase3/includes/Title.php |
— | — | @@ -2718,9 +2718,7 @@ |
2719 | 2719 | $fname = 'MovePageForm::moveToNewTitle'; |
2720 | 2720 | $comment = wfMsgForContent( '1movedto2', $this->getPrefixedText(), $nt->getPrefixedText() ); |
2721 | 2721 | if ( $reason ) { |
2722 | | - $comment .= wfMsgExt( 'colon-separator', |
2723 | | - array( 'escapenoentities', 'content' ) ); |
2724 | | - $comment .= $reason; |
| 2722 | + $comment .= ": $reason"; |
2725 | 2723 | } |
2726 | 2724 | |
2727 | 2725 | $newid = $nt->getArticleID(); |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -189,9 +189,6 @@ |
190 | 190 | * (bug 9736) Redirects on Special:Fewestrevisions are now marked as such. |
191 | 191 | * New date/time formats in Cs localization according to ČSN and PČP. |
192 | 192 | * Added new hook LinkerLinkAttributes for modifying attributes of <a> tags. |
193 | | -* HTML entities like now work (are not escaped) in edit summaries. |
194 | | -* (bug 13815) In the comment for page moves, use the colon-separator message |
195 | | - instead of a hardcoded colon. |
196 | 193 | * Add a new hook SkinSetupSiteCss to allow extensions to define new stylesheets |
197 | 194 | to load site wide, or modify the list of stylesheets to load. This can be useful |
198 | 195 | for wiki farms who need a specific placement of the stylesheets to cascade right. |