diff options
Diffstat (limited to 'mod/bookmarks/pages/view.php')
-rw-r--r-- | mod/bookmarks/pages/view.php | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/mod/bookmarks/pages/view.php b/mod/bookmarks/pages/view.php new file mode 100644 index 000000000..6b4b839b1 --- /dev/null +++ b/mod/bookmarks/pages/view.php @@ -0,0 +1,36 @@ +<?php +/** + * View a bookmark + * + * @package ElggBookmarks + */ + +$bookmark = get_entity(get_input('guid')); + +elgg_set_page_owner_guid($bookmark->getContainerGUID()); +$owner = elgg_get_page_owner_entity(); + +elgg_push_breadcrumb(elgg_echo('bookmarks'), 'pg/bookmarks/all'); + +$crumbs_title = elgg_echo('blog:owned_blogs', array($owner->name)); +if (elgg_instanceof($owner, 'group')) { + elgg_push_breadcrumb($crumbs_title, "pg/bookmarks/group/$owner->guid/owner"); +} else { + elgg_push_breadcrumb($crumbs_title, "pg/bookmarks/owner/$owner->username"); +} + +$title = $bookmark->title; + +elgg_push_breadcrumb($title); + +$content = elgg_view_entity($bookmark, true); +$content .= elgg_view_comments($bookmark); + +$body = elgg_view_layout('content', array( + 'content' => $content, + 'title' => $title, + 'filter' => '', + 'header' => '', +)); + +echo elgg_view_page($title, $body); |