aboutsummaryrefslogtreecommitdiffstats
path: root/include/bb2diaspora.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-09-03 22:00:18 -0700
committerfriendica <info@friendica.com>2014-09-03 22:00:18 -0700
commit6ad9d9f8454b1a44800a406d9eeaaa45ed10e8da (patch)
treeeaa800d76085a8c45e2e5f43fffd6db6eddee34f /include/bb2diaspora.php
parent96a9378fd74eb45599ef2152d55286293968b298 (diff)
downloadvolse-hubzilla-6ad9d9f8454b1a44800a406d9eeaaa45ed10e8da.tar.gz
volse-hubzilla-6ad9d9f8454b1a44800a406d9eeaaa45ed10e8da.tar.bz2
volse-hubzilla-6ad9d9f8454b1a44800a406d9eeaaa45ed10e8da.zip
sort out some of the bb2d madness
Diffstat (limited to 'include/bb2diaspora.php')
-rw-r--r--include/bb2diaspora.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/bb2diaspora.php b/include/bb2diaspora.php
index 622f239ad..9c8c05aeb 100644
--- a/include/bb2diaspora.php
+++ b/include/bb2diaspora.php
@@ -252,6 +252,7 @@ function bb2diaspora_itembody($item) {
if($item['diaspora_meta']) {
$j = json_decode($item['diaspora_meta'],true);
if($j && $j['body']) {
+ logger('bb2diaspora_itembody: cached ');
return $j['body'];
}
}
@@ -299,6 +300,8 @@ function bb2diaspora_itembody($item) {
}
}
+ logger('bb2diaspora_itembody : ' . $body);
+
return html_entity_decode($body);
}
@@ -316,10 +319,7 @@ function bb2diaspora($Text,$preserve_nl = false, $fordiaspora = true) {
'return \'#\'. str_replace(\' \', \'_\', $match[3]);'
), $Text);
- $Text = preg_replace_callback('/#\^\[([zu])rl\=(\w+.*?)\](\w+.*?)\[\/[(zu)]rl\]/i', create_function('$match',
- 'return str_replace(\' \', \'_\', $match[3]);'
- ), $Text);
-
+ $Text = preg_replace('/#\^\[([zu])rl\=(\w+.*?)\](\w+.*?)\[\/([zu])rl\]/i', '[$1rl=$2]$3[/$4rl]', $Text);
$Text = preg_replace_callback('/\@\!?\[([zu])rl\=(\w+.*?)\](\w+.*?)\[\/([zu])rl\]/i', 'bb2dmention_callback', $Text);