aboutsummaryrefslogtreecommitdiff
path: root/mod/bookmarks/pages
diff options
context:
space:
mode:
Diffstat (limited to 'mod/bookmarks/pages')
-rw-r--r--mod/bookmarks/pages/bookmarks/all.php4
-rw-r--r--mod/bookmarks/pages/bookmarks/friends.php11
-rw-r--r--mod/bookmarks/pages/bookmarks/owner.php3
-rw-r--r--mod/bookmarks/pages/bookmarks/view.php1
4 files changed, 14 insertions, 5 deletions
diff --git a/mod/bookmarks/pages/bookmarks/all.php b/mod/bookmarks/pages/bookmarks/all.php
index d9ac2767f..f57776752 100644
--- a/mod/bookmarks/pages/bookmarks/all.php
+++ b/mod/bookmarks/pages/bookmarks/all.php
@@ -20,6 +20,10 @@ $content = elgg_list_entities(array(
'view_toggle_type' => false
));
+if (!$content) {
+ $content = elgg_echo('bookmarks:none');
+}
+
$title = elgg_echo('bookmarks:everyone');
$body = elgg_view_layout('content', array(
diff --git a/mod/bookmarks/pages/bookmarks/friends.php b/mod/bookmarks/pages/bookmarks/friends.php
index 3491090a5..15b1da098 100644
--- a/mod/bookmarks/pages/bookmarks/friends.php
+++ b/mod/bookmarks/pages/bookmarks/friends.php
@@ -5,16 +5,19 @@
* @package ElggBookmarks
*/
-$owner = elgg_get_page_owner_entity();
+$page_owner = elgg_get_page_owner_entity();
+if (!$page_owner) {
+ forward('bookmarks/all');
+}
-elgg_push_breadcrumb($owner->name, "bookmarks/owner/$owner->username");
+elgg_push_breadcrumb($page_owner->name, "bookmarks/owner/$page_owner->username");
elgg_push_breadcrumb(elgg_echo('friends'));
elgg_register_title_button();
$title = elgg_echo('bookmarks:friends');
-$content = list_user_friends_objects($owner->guid, 'bookmarks', 10, false);
+$content = list_user_friends_objects($page_owner->guid, 'bookmarks', 10, false);
if (!$content) {
$content = elgg_echo('bookmarks:none');
}
@@ -27,4 +30,4 @@ $params = array(
$body = elgg_view_layout('content', $params);
-echo elgg_view_page($title, $body); \ No newline at end of file
+echo elgg_view_page($title, $body);
diff --git a/mod/bookmarks/pages/bookmarks/owner.php b/mod/bookmarks/pages/bookmarks/owner.php
index 679c986be..7f55e08de 100644
--- a/mod/bookmarks/pages/bookmarks/owner.php
+++ b/mod/bookmarks/pages/bookmarks/owner.php
@@ -6,6 +6,9 @@
*/
$page_owner = elgg_get_page_owner_entity();
+if (!$page_owner) {
+ forward('bookmarks/all');
+}
elgg_push_breadcrumb($page_owner->name);
diff --git a/mod/bookmarks/pages/bookmarks/view.php b/mod/bookmarks/pages/bookmarks/view.php
index 8e097b090..2439d2ee8 100644
--- a/mod/bookmarks/pages/bookmarks/view.php
+++ b/mod/bookmarks/pages/bookmarks/view.php
@@ -28,7 +28,6 @@ $body = elgg_view_layout('content', array(
'content' => $content,
'title' => $title,
'filter' => '',
- 'header' => '',
));
echo elgg_view_page($title, $body);