diff --git a/wp-includes/functions-formatting.php b/wp-includes/functions-formatting.php
index 661374bd0c..8726f33556 100644
--- a/wp-includes/functions-formatting.php
+++ b/wp-includes/functions-formatting.php
@@ -46,6 +46,12 @@ function wptexturize($text) {
return $output;
}
+function clean_pre($text) {
+ $text = stripslashes($text);
+ $text = str_replace('
', '', $text);
+ return $text;
+}
+
function wpautop($pee, $br = 1) {
$pee = $pee . "\n"; // just to make things a little easier, pad the end
$pee = preg_replace('|
\s*
|', "\n\n", $pee);
@@ -64,6 +70,7 @@ function wpautop($pee, $br = 1) {
if ($br) $pee = preg_replace('|(?)\s*\n|', "
\n", $pee); // optionally make line breaks
$pee = preg_replace('!(?(?:table|thead|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|select|form|blockquote|p|h[1-6])[^>]*>)\s*
!', "$1", $pee);
$pee = preg_replace('!
(\s*?(?:p|li|div|dl|dd|dt|th|pre|td|ul|ol)>)!', '$1', $pee);
+ $pee = preg_replace('!(