aboutsummaryrefslogtreecommitdiff
path: root/mod/bookmarks
diff options
context:
space:
mode:
Diffstat (limited to 'mod/bookmarks')
-rw-r--r--mod/bookmarks/actions/bookmarks/save.php2
-rw-r--r--mod/bookmarks/languages/en.php11
-rw-r--r--mod/bookmarks/pages/bookmarks/all.php2
-rw-r--r--mod/bookmarks/pages/bookmarks/owner.php2
-rw-r--r--mod/bookmarks/start.php24
5 files changed, 19 insertions, 22 deletions
diff --git a/mod/bookmarks/actions/bookmarks/save.php b/mod/bookmarks/actions/bookmarks/save.php
index f240c4b26..3ca6bef32 100644
--- a/mod/bookmarks/actions/bookmarks/save.php
+++ b/mod/bookmarks/actions/bookmarks/save.php
@@ -5,8 +5,6 @@
* @package Bookmarks
*/
-gatekeeper();
-
$title = strip_tags(get_input('title'));
$description = get_input('description');
$address = get_input('address');
diff --git a/mod/bookmarks/languages/en.php b/mod/bookmarks/languages/en.php
index 2c589c207..d4980280d 100644
--- a/mod/bookmarks/languages/en.php
+++ b/mod/bookmarks/languages/en.php
@@ -23,10 +23,19 @@ $english = array(
'bookmarks:more' => "More",
'bookmarks:with' => "Share with",
'bookmarks:new' => "A new bookmark",
- 'bookmarks:via' => "via bookmarks",
'bookmarks:address' => "Address of the bookmark",
'bookmarks:none' => 'No bookmarks',
+ 'bookmarks:notification' =>
+'%s added a new bookmark:
+
+%s - %s
+%s
+
+View and comment on the new bookmark:
+%s
+',
+
'bookmarks:delete:confirm' => "Are you sure you want to delete this resource?",
'bookmarks:numbertodisplay' => 'Number of bookmarks to display',
diff --git a/mod/bookmarks/pages/bookmarks/all.php b/mod/bookmarks/pages/bookmarks/all.php
index f57776752..bdb8fc793 100644
--- a/mod/bookmarks/pages/bookmarks/all.php
+++ b/mod/bookmarks/pages/bookmarks/all.php
@@ -10,12 +10,10 @@ elgg_push_breadcrumb(elgg_echo('bookmarks'));
elgg_register_title_button();
-$offset = (int)get_input('offset', 0);
$content = elgg_list_entities(array(
'type' => 'object',
'subtype' => 'bookmarks',
'limit' => 10,
- 'offset' => $offset,
'full_view' => false,
'view_toggle_type' => false
));
diff --git a/mod/bookmarks/pages/bookmarks/owner.php b/mod/bookmarks/pages/bookmarks/owner.php
index 7f55e08de..a024ff352 100644
--- a/mod/bookmarks/pages/bookmarks/owner.php
+++ b/mod/bookmarks/pages/bookmarks/owner.php
@@ -14,13 +14,11 @@ elgg_push_breadcrumb($page_owner->name);
elgg_register_title_button();
-$offset = (int)get_input('offset', 0);
$content .= elgg_list_entities(array(
'type' => 'object',
'subtype' => 'bookmarks',
'container_guid' => $page_owner->guid,
'limit' => 10,
- 'offset' => $offset,
'full_view' => false,
'view_toggle_type' => false
));
diff --git a/mod/bookmarks/start.php b/mod/bookmarks/start.php
index 21a2d8940..56bac984a 100644
--- a/mod/bookmarks/start.php
+++ b/mod/bookmarks/start.php
@@ -245,21 +245,15 @@ function bookmarks_notify_message($hook, $entity_type, $returnvalue, $params) {
if (($entity instanceof ElggEntity) && ($entity->getSubtype() == 'bookmarks')) {
$descr = $entity->description;
$title = $entity->title;
- global $CONFIG;
- $url = elgg_get_site_url() . "view/" . $entity->guid;
- if ($method == 'sms') {
- $owner = $entity->getOwnerEntity();
- return $owner->name . ' ' . elgg_echo("bookmarks:via") . ': ' . $url . ' (' . $title . ')';
- }
- if ($method == 'email') {
- $owner = $entity->getOwnerEntity();
- return $owner->name . ' ' . elgg_echo("bookmarks:via") . ': ' . $title . "\n\n" . $descr . "\n\n" . $entity->getURL();
- }
- if ($method == 'web') {
- $owner = $entity->getOwnerEntity();
- return $owner->name . ' ' . elgg_echo("bookmarks:via") . ': ' . $title . "\n\n" . $descr . "\n\n" . $entity->getURL();
- }
-
+ $owner = $entity->getOwnerEntity();
+
+ return elgg_echo('bookmarks:notification', array(
+ $owner->name,
+ $title,
+ $entity->address,
+ $descr,
+ $entity->getURL()
+ ));
}
return null;
}