aboutsummaryrefslogtreecommitdiffstats
path: root/include/activities.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-12-21 14:43:06 -0800
committerfriendica <info@friendica.com>2014-12-21 14:43:06 -0800
commit2b3cc585a24cbdf97e8e2382752297bc4f725e12 (patch)
tree59714f4ca85b0598437f0e2beff3bd1bbf5816db /include/activities.php
parent0c98cacbcf0c27aba6bea62b4bf3dc00c91b3962 (diff)
downloadvolse-hubzilla-2b3cc585a24cbdf97e8e2382752297bc4f725e12.tar.gz
volse-hubzilla-2b3cc585a24cbdf97e8e2382752297bc4f725e12.tar.bz2
volse-hubzilla-2b3cc585a24cbdf97e8e2382752297bc4f725e12.zip
fix double encoding of homepage in profile activity - not as straight-forward as it looked
Diffstat (limited to 'include/activities.php')
-rw-r--r--include/activities.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/activities.php b/include/activities.php
index d978ebcd6..d770ccb23 100644
--- a/include/activities.php
+++ b/include/activities.php
@@ -48,7 +48,11 @@ function profile_activity($changed, $value) {
if($t == 1 && strlen($value)) {
// if it's a url, the HTML quotes will mess it up, so link it and don't try and zidify it because we don't know what it points to.
- $value = linkify($value);
+ $value = preg_replace_callback("/([^\]\='".'"'."]|^|\#\^)(https?\:\/\/[a-zA-Z0-9\:\/\-\?\&\;\.\=\@\_\~\#\%\$\!\+\,]+)/ism", 'red_zrl_callback', $value);
+ // take out the bookmark indicator
+ if(substr($value,0,2) === '#^')
+ $value = str_replace('#^','',$value);
+
$message = sprintf( t('%1$s changed %2$s to &ldquo;%3$s&rdquo;'), $A, $changes, $value);
$message .= "\n\n" . sprintf( t('Visit %1$s\'s %2$s'), $A, $prof);
}