aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mod/bookmarks.php11
1 files changed, 10 insertions, 1 deletions
diff --git a/mod/bookmarks.php b/mod/bookmarks.php
index 02fe2f2e1..5c48ce5a9 100644
--- a/mod/bookmarks.php
+++ b/mod/bookmarks.php
@@ -4,6 +4,8 @@ function bookmarks_init(&$a) {
if(! local_channel())
return;
$item_id = intval($_REQUEST['item']);
+ $burl = trim($_REQUEST['burl']);
+
if(! $item_id)
return;
@@ -36,7 +38,14 @@ function bookmarks_init(&$a) {
killme();
}
foreach($terms as $t) {
- bookmark_add($u,$s[0],$t,$item['item_private']);
+ if($burl) {
+ if($burl == $t['url']) {
+ bookmark_add($u,$s[0],$t,$item['item_private']);
+ }
+ }
+ else
+ bookmark_add($u,$s[0],$t,$item['item_private']);
+
info( t('Bookmark added') . EOL);
}
}