From 93b9d713776bd18e9a3126f025a0c63c8589c201 Mon Sep 17 00:00:00 2001 From: Friendika Date: Fri, 2 Sep 2011 05:13:38 -0700 Subject: [PATCH] completely enclose ~f hashtags so they don't get hijacked by D* --- include/bb2diaspora.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/bb2diaspora.php b/include/bb2diaspora.php index 92f492116f..2eeea32cd7 100644 --- a/include/bb2diaspora.php +++ b/include/bb2diaspora.php @@ -58,7 +58,8 @@ function bb2diaspora($Text,$preserve_nl = false) { $Text = preg_replace("/\[url\]([$URLSearchString]*)\[\/url\]/", '[$1]($1)', $Text); - $Text = preg_replace("(\[url\=([$URLSearchString]*)\](.*?)\[/url\])", '[$2]($1)', $Text); + $Text = preg_replace("/\#\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/", '[#$2]($1)', $Text); + $Text = preg_replace("/\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/", '[$2]($1)', $Text); // $Text = preg_replace("/\[img\](.*?)\[\/img\]/", t('Image/photo: ') . '$1', $Text); // $Text = preg_replace("/\[img\](.*?)\[\/img\]/", t('image/photo'), $Text);