Ticket #20421: 20421.diff
File 20421.diff, 1.0 KB (added by , 13 years ago) |
---|
-
wp-includes/kses.php
551 551 if ( empty( $allowed_protocols ) ) 552 552 $allowed_protocols = wp_allowed_protocols(); 553 553 $string = wp_kses_no_null($string); 554 $string = wp_kses_js_entities($string);555 554 $string = wp_kses_normalize_entities($string); 556 555 $allowed_html_fixed = wp_kses_array_lc($allowed_html); 557 556 $string = wp_kses_hook($string, $allowed_html_fixed, $allowed_protocols); // WP changed the order of these funcs and added args to wp_kses_hook … … 1041 1040 } 1042 1041 1043 1042 /** 1044 * Removes the HTML JavaScript entities found in early versions of Netscape 4.1045 *1046 * @since 1.0.01047 *1048 * @param string $string1049 * @return string1050 */1051 function wp_kses_js_entities($string) {1052 return preg_replace('%&\s*\{[^}]*(\}\s*;?|$)%', '', $string);1053 }1054 1055 /**1056 1043 * Handles parsing errors in wp_kses_hair(). 1057 1044 * 1058 1045 * The general plan is to remove everything to and including some whitespace,