diff options
author | Steven Wittens <steven@10.no-reply.drupal.org> | 2006-12-12 09:51:21 +0000 |
---|---|---|
committer | Steven Wittens <steven@10.no-reply.drupal.org> | 2006-12-12 09:51:21 +0000 |
commit | 991098b985bc6f31b902637180f9eba1c745de42 (patch) | |
tree | cca71043d2e9a289cc4fd47e8b670512a56f49e3 | |
parent | 2c3f9537ed85f4b6170d7b0452513806e0d779de (diff) | |
download | brdo-991098b985bc6f31b902637180f9eba1c745de42.tar.gz brdo-991098b985bc6f31b902637180f9eba1c745de42.tar.bz2 |
#100679: filter.module - Don't add unnecessary <br /> to empty output.
-rw-r--r-- | modules/filter/filter.module | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/filter/filter.module b/modules/filter/filter.module index ec75d9199..2a585a27d 100644 --- a/modules/filter/filter.module +++ b/modules/filter/filter.module @@ -1207,7 +1207,7 @@ function _filter_autop($text) { $chunk = preg_replace('!(</'. $block .'>)!', "$1\n\n", $chunk); // Space things out a little $chunk = preg_replace("/\n\n+/", "\n\n", $chunk); // take care of duplicates $chunk = preg_replace('/\n?(.+?)(?:\n\s*\n|\z)/s', "<p>$1</p>\n", $chunk); // make paragraphs, including one at the end - $chunk = preg_replace('|<p>\s*?</p>|', '', $chunk); // under certain strange conditions it could create a P of entirely whitespace + $chunk = preg_replace('|<p>\s*?</p>\n|', '', $chunk); // under certain strange conditions it could create a P of entirely whitespace $chunk = preg_replace("|<p>(<li.+?)</p>|", "$1", $chunk); // problem with nested lists $chunk = preg_replace('|<p><blockquote([^>]*)>|i', "<blockquote$1><p>", $chunk); $chunk = str_replace('</blockquote></p>', '</p></blockquote>', $chunk); |