Ticket #11249: autop.diff
| File autop.diff, 778 bytes (added by , 16 years ago) |
|---|
-
formatting.php
216 216 if (strpos($pee, '<pre') !== false) 217 217 $pee = preg_replace_callback('!(<pre[^>]*>)(.*?)</pre>!is', 'clean_pre', $pee ); 218 218 $pee = preg_replace( "|\n</p>$|", '</p>', $pee ); 219 $pee = preg_replace('/<p>\s*?(' . get_shortcode_regex() . ')\s*<\/p>/s', '$1', $pee); // don't auto-p wrap shortcodes that stand alone 219 if ( function_exists( 'get_shortcode_regex' ) ) 220 $pee = preg_replace('/<p>\s*?(' . get_shortcode_regex() . ')\s*<\/p>/s', '$1', $pee); // don't auto-p wrap shortcodes that stand alone 220 221 221 222 return $pee; 222 223 }