aboutsummaryrefslogtreecommitdiffstats
path: root/include/bbcode.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-07-02 01:11:19 -0700
committerfriendica <info@friendica.com>2012-07-02 01:11:19 -0700
commit315784444af3145e6afba210731f0104d21f9db3 (patch)
tree56f4c6621a94afffeef574ba202733dc144ad30a /include/bbcode.php
parenta9c65dfe2725fd18d2fb1f593f9ffb9841729a96 (diff)
downloadvolse-hubzilla-315784444af3145e6afba210731f0104d21f9db3.tar.gz
volse-hubzilla-315784444af3145e6afba210731f0104d21f9db3.tar.bz2
volse-hubzilla-315784444af3145e6afba210731f0104d21f9db3.zip
try and get unadulterated bb2md2html2bb for simple stuff, then we'll work up to harder stuff
Diffstat (limited to 'include/bbcode.php')
-rw-r--r--include/bbcode.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/bbcode.php b/include/bbcode.php
index 9071c767b..1c6ce1d45 100644
--- a/include/bbcode.php
+++ b/include/bbcode.php
@@ -93,11 +93,15 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true) {
// Convert new line chars to html <br /> tags
- $Text = nl2br($Text);
+
+// $Text = nl2br($Text);
+ $Text = str_replace(array("\r","\n"), array('<br />','<br />'), $Text);
+
if($preserve_nl)
$Text = str_replace(array("\n","\r"), array('',''),$Text);
+
// Set up the parameters for a URL search string
$URLSearchString = "^\[\]";
// Set up the parameters for a MAIL search string