aboutsummaryrefslogtreecommitdiffstats
path: root/boot.php
diff options
context:
space:
mode:
authorMike Macgirvin <mike@macgirvin.com>2010-10-31 21:57:30 -0700
committerMike Macgirvin <mike@macgirvin.com>2010-10-31 21:57:30 -0700
commit4f4d6bace60fa3f43efeb675ba4f1617a9d9df58 (patch)
treeffad8f6faf4c42def511898377dd39e031a73d8b /boot.php
parentb376f215337e4bee7320a0df8fc3d9b1beb2f289 (diff)
downloadvolse-hubzilla-4f4d6bace60fa3f43efeb675ba4f1617a9d9df58.tar.gz
volse-hubzilla-4f4d6bace60fa3f43efeb675ba4f1617a9d9df58.tar.bz2
volse-hubzilla-4f4d6bace60fa3f43efeb675ba4f1617a9d9df58.zip
add rel=mentioned links for tagged persons
Diffstat (limited to 'boot.php')
-rw-r--r--boot.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/boot.php b/boot.php
index 30e5a111e..2de398cfc 100644
--- a/boot.php
+++ b/boot.php
@@ -1358,3 +1358,17 @@ function like_puller($a,$item,&$arr,$mode) {
return;
}}
+
+function get_mentions($item) {
+ $o = '';
+ if(! strlen($item['tag']))
+ return $o;
+
+ $arr = explode(',',$item['tag']);
+ foreach($arr as $x) {
+ $matches = null;
+ if(preg_match('/@\[url=([^\]]*)\]/',$x,$matches))
+ $o .= "\t\t" . '<link rel="mentioned" href="' . $matches[1] . '" />' . "\r\n";
+ }
+ return $o;
+} \ No newline at end of file