aboutsummaryrefslogtreecommitdiff
path: root/mod/pages
diff options
context:
space:
mode:
Diffstat (limited to 'mod/pages')
-rw-r--r--mod/pages/pages/pages/edit.php1
-rw-r--r--mod/pages/pages/pages/friends.php2
-rw-r--r--mod/pages/pages/pages/history.php1
-rw-r--r--mod/pages/pages/pages/new.php1
-rw-r--r--mod/pages/pages/pages/owner.php2
-rw-r--r--mod/pages/pages/pages/revision.php1
-rw-r--r--mod/pages/pages/pages/view.php12
-rw-r--r--mod/pages/pages/pages/world.php2
8 files changed, 11 insertions, 11 deletions
diff --git a/mod/pages/pages/pages/edit.php b/mod/pages/pages/pages/edit.php
index 8e530084b..e6c2ea015 100644
--- a/mod/pages/pages/pages/edit.php
+++ b/mod/pages/pages/pages/edit.php
@@ -34,7 +34,6 @@ if ($page->canEdit()) {
$body = elgg_view_layout('content', array(
'filter' => '',
- 'buttons' => '',
'content' => $content,
'title' => $title,
));
diff --git a/mod/pages/pages/pages/friends.php b/mod/pages/pages/pages/friends.php
index 13aa28578..88f26c45d 100644
--- a/mod/pages/pages/pages/friends.php
+++ b/mod/pages/pages/pages/friends.php
@@ -13,6 +13,8 @@ if (!$owner) {
elgg_push_breadcrumb($owner->name, "pages/owner/$owner->username");
elgg_push_breadcrumb(elgg_echo('friends'));
+elgg_register_add_button();
+
$title = elgg_echo('pages:friends');
$content = list_user_friends_objects($owner->guid, 'page_top', 10, false);
diff --git a/mod/pages/pages/pages/history.php b/mod/pages/pages/pages/history.php
index a7ef57b6b..a63b37a7a 100644
--- a/mod/pages/pages/pages/history.php
+++ b/mod/pages/pages/pages/history.php
@@ -34,7 +34,6 @@ $content = list_annotations($page_guid, 'page', 20, false);
$body = elgg_view_layout('content', array(
'filter' => '',
- 'buttons' => '',
'content' => $content,
'title' => $title,
'sidebar' => elgg_view('pages/sidebar/navigation', array('page' => $page)),
diff --git a/mod/pages/pages/pages/new.php b/mod/pages/pages/pages/new.php
index 42a8e04e1..7cab2facb 100644
--- a/mod/pages/pages/pages/new.php
+++ b/mod/pages/pages/pages/new.php
@@ -30,7 +30,6 @@ $content = elgg_view_form('pages/edit', array(), $vars);
$body = elgg_view_layout('content', array(
'filter' => '',
- 'buttons' => '',
'content' => $content,
'title' => $title,
));
diff --git a/mod/pages/pages/pages/owner.php b/mod/pages/pages/pages/owner.php
index c1169085f..312b56a54 100644
--- a/mod/pages/pages/pages/owner.php
+++ b/mod/pages/pages/pages/owner.php
@@ -17,6 +17,8 @@ $title = elgg_echo('pages:owner', array($owner->name));
elgg_push_breadcrumb($owner->name);
+elgg_register_add_button();
+
$content = elgg_list_entities(array(
'types' => 'object',
'subtypes' => 'page_top',
diff --git a/mod/pages/pages/pages/revision.php b/mod/pages/pages/pages/revision.php
index 83d72286c..66a36e4e7 100644
--- a/mod/pages/pages/pages/revision.php
+++ b/mod/pages/pages/pages/revision.php
@@ -45,7 +45,6 @@ $sidebar = elgg_view('pages/sidebar/history', array('page' => $page));
$body = elgg_view_layout('content', array(
'filter' => '',
- 'buttons' => '',
'content' => $content,
'title' => $title,
'sidebar' => $sidebar,
diff --git a/mod/pages/pages/pages/view.php b/mod/pages/pages/pages/view.php
index 06064d993..5dfb76b55 100644
--- a/mod/pages/pages/pages/view.php
+++ b/mod/pages/pages/pages/view.php
@@ -32,20 +32,18 @@ elgg_push_breadcrumb($title);
$content = elgg_view_entity($page, array('full_view' => true));
$content .= elgg_view_comments($page);
-$buttons = '';
if (elgg_get_logged_in_user_guid() == $page->getOwnerGuid()) {
$url = "pages/add/$page->guid";
- $buttons = elgg_view('output/url', array(
- 'text' => elgg_echo('pages:newchild'),
+ elgg_register_menu_item('title', array(
+ 'name' => 'subpage',
'href' => $url,
- 'class' => 'elgg-button elgg-button-action',
- ));
- $buttons = "<ul class=\"elgg-menu elgg-menu-title\"><li>$buttons</li></ul>";
+ 'text' => elgg_echo('pages:newchild'),
+ 'link_class' => 'elgg-button elgg-button-action',
+ ));
}
$body = elgg_view_layout('content', array(
'filter' => '',
- 'buttons' => $buttons,
'content' => $content,
'title' => $title,
'sidebar' => elgg_view('pages/sidebar/navigation'),
diff --git a/mod/pages/pages/pages/world.php b/mod/pages/pages/pages/world.php
index 267670144..9237a820e 100644
--- a/mod/pages/pages/pages/world.php
+++ b/mod/pages/pages/pages/world.php
@@ -10,6 +10,8 @@ $title = elgg_echo('pages:all');
elgg_pop_breadcrumb();
elgg_push_breadcrumb(elgg_echo('pages'));
+elgg_register_add_button();
+
$content = elgg_list_entities(array(
'types' => 'object',
'subtypes' => 'page_top',