aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-07-04 23:24:59 -0700
committerfriendica <info@friendica.com>2012-07-04 23:24:59 -0700
commit360c35e438f4ecb6a60cefde8ab8b0e3f6f0c57f (patch)
treed079adf866a45d0efed12b4a6700b16c7b58f363 /include
parente29dd081cabe5861895ff2e16c4354caad7b1b13 (diff)
downloadvolse-hubzilla-360c35e438f4ecb6a60cefde8ab8b0e3f6f0c57f.tar.gz
volse-hubzilla-360c35e438f4ecb6a60cefde8ab8b0e3f6f0c57f.tar.bz2
volse-hubzilla-360c35e438f4ecb6a60cefde8ab8b0e3f6f0c57f.zip
recycle symbol woes with multiple html entity encode/decode cycles going on
Diffstat (limited to 'include')
-rw-r--r--include/bb2diaspora.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/bb2diaspora.php b/include/bb2diaspora.php
index d756b922d..c93b60d0d 100644
--- a/include/bb2diaspora.php
+++ b/include/bb2diaspora.php
@@ -44,6 +44,9 @@ function diaspora2bb($s) {
$s = html2bbcode($s);
// $s = str_replace('&#42;','*',$s);
+ // protect the recycle symbol from turning into a tag, but without unescaping angles and naked ampersands
+ $s = str_replace('&#x2672;',html_entities_decode('&#x2672;',ENT_QUOTES,'UTF-8'),$s);
+
// Convert everything that looks like a link to a link
$s = preg_replace("/([^\]\=]|^)(https?\:\/\/)([a-zA-Z0-9\:\/\-\?\&\;\.\=\_\~\#\%\$\!\+\,]+)/ism", '$1[url=$2$3]$2$3[/url]',$s);