Ticket #21018: 21018.diff
File 21018.diff, 966 bytes (added by , 12 years ago) |
---|
-
wp-includes/formatting.php
236 236 foreach ( $pees as $tinkle ) 237 237 $pee .= '<p>' . trim($tinkle, "\n") . "</p>\n"; 238 238 $pee = preg_replace('|<p>\s*</p>|', '', $pee); // under certain strange conditions it could create a P of entirely whitespace 239 $pee = preg_replace('!<p>\s*(</?' . $allblocks . '[^>]*>)\s*</p>!', "$1", $pee); // don't pee all over a tag 239 240 $pee = preg_replace('!<p>([^<]+)</(div|address|form)>!', "<p>$1</p></$2>", $pee); 240 $pee = preg_replace('!<p>\s*(</?' . $allblocks . '[^>]*>)\s*</p>!', "$1", $pee); // don't pee all over a tag241 241 $pee = preg_replace("|<p>(<li.+?)</p>|", "$1", $pee); // problem with nested lists 242 242 $pee = preg_replace('|<p><blockquote([^>]*)>|i', "<blockquote$1><p>", $pee); 243 243 $pee = str_replace('</blockquote></p>', '</p></blockquote>', $pee);