aboutsummaryrefslogtreecommitdiffstats
path: root/mod/item.php
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-01-23 16:29:30 -0800
committerFriendika <info@friendika.com>2011-01-23 16:29:30 -0800
commit00d2b583588ea1c55e9b478809e8041d6ba98639 (patch)
tree07ad38acb1beae1bce4bc56416cc64c8ad95abc8 /mod/item.php
parent1460fc0d710ce14d6c746eb06fc8f3a5372493c2 (diff)
downloadvolse-hubzilla-00d2b583588ea1c55e9b478809e8041d6ba98639.tar.gz
volse-hubzilla-00d2b583588ea1c55e9b478809e8041d6ba98639.tar.bz2
volse-hubzilla-00d2b583588ea1c55e9b478809e8041d6ba98639.zip
fix a few issues with code blocks, ignore tags within blocks, fold multi-line blocks to one, also turn html br into two LFs.
Diffstat (limited to 'mod/item.php')
-rw-r--r--mod/item.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/mod/item.php b/mod/item.php
index f964e7737..feef7c95f 100644
--- a/mod/item.php
+++ b/mod/item.php
@@ -165,7 +165,11 @@ function item_post(&$a) {
}
}
+ /**
+ * Fold multi-line [code] sequences
+ */
+ $body = preg_replace('/\[\/code\]\s*\[code\]/m',"\n",$body);
/**
* Look for any tags and linkify them