aboutsummaryrefslogtreecommitdiff
path: root/mod
diff options
context:
space:
mode:
Diffstat (limited to 'mod')
-rw-r--r--mod/file/pages/file/owner.php4
-rw-r--r--mod/file/pages/file/world.php1
-rw-r--r--mod/file/views/default/file/sidebar.php9
-rw-r--r--mod/pages/pages/pages/owner.php5
-rw-r--r--mod/pages/pages/pages/world.php1
-rw-r--r--mod/pages/views/default/pages/sidebar.php9
6 files changed, 25 insertions, 4 deletions
diff --git a/mod/file/pages/file/owner.php b/mod/file/pages/file/owner.php
index 617e4c7f4..b7bfb00f8 100644
--- a/mod/file/pages/file/owner.php
+++ b/mod/file/pages/file/owner.php
@@ -56,9 +56,7 @@ if (!$content) {
}
$sidebar = file_get_type_cloud(elgg_get_page_owner_guid());
-if (elgg_instanceof($owner, 'user')) {
- $sidebar .= elgg_view_latest_comments(elgg_get_page_owner_guid(), 'object', 'file');
-}
+$sidebar = elgg_view('file/sidebar');
$params['content'] = $content;
$params['title'] = $title;
diff --git a/mod/file/pages/file/world.php b/mod/file/pages/file/world.php
index a55dcb452..2cd942369 100644
--- a/mod/file/pages/file/world.php
+++ b/mod/file/pages/file/world.php
@@ -21,6 +21,7 @@ $content = elgg_list_entities(array(
elgg_pop_context();
$sidebar = file_get_type_cloud();
+$sidebar = elgg_view('file/sidebar');
$body = elgg_view_layout('content', array(
'filter_context' => 'all',
diff --git a/mod/file/views/default/file/sidebar.php b/mod/file/views/default/file/sidebar.php
new file mode 100644
index 000000000..864965e98
--- /dev/null
+++ b/mod/file/views/default/file/sidebar.php
@@ -0,0 +1,9 @@
+<?php
+/**
+ * File sidebar
+ */
+
+echo elgg_view('page/elements/comments_block', array(
+ 'subtypes' => 'file',
+ 'owner_guid' => elgg_get_page_owner_guid(),
+));
diff --git a/mod/pages/pages/pages/owner.php b/mod/pages/pages/pages/owner.php
index 6a89e6092..c1169085f 100644
--- a/mod/pages/pages/pages/owner.php
+++ b/mod/pages/pages/pages/owner.php
@@ -33,11 +33,14 @@ if (elgg_get_page_owner_guid() == elgg_get_logged_in_user_guid()) {
$filter_context = 'mine';
}
+$sidebar = elgg_view('pages/sidebar/navigation');
+$sidebar .= elgg_view('pages/sidebar');
+
$params = array(
'filter_context' => $filter_context,
'content' => $content,
'title' => $title,
- 'sidebar' => elgg_view('pages/sidebar/navigation'),
+ 'sidebar' => $sidebar,
);
if (elgg_instanceof($owner, 'group')) {
diff --git a/mod/pages/pages/pages/world.php b/mod/pages/pages/pages/world.php
index 668100ad2..267670144 100644
--- a/mod/pages/pages/pages/world.php
+++ b/mod/pages/pages/pages/world.php
@@ -23,6 +23,7 @@ $body = elgg_view_layout('content', array(
'filter_context' => 'all',
'content' => $content,
'title' => $title,
+ 'sidebar' => elgg_view('pages/sidebar'),
));
echo elgg_view_page($title, $body);
diff --git a/mod/pages/views/default/pages/sidebar.php b/mod/pages/views/default/pages/sidebar.php
new file mode 100644
index 000000000..553335dc0
--- /dev/null
+++ b/mod/pages/views/default/pages/sidebar.php
@@ -0,0 +1,9 @@
+<?php
+/**
+ * Pages sidebar
+ */
+
+echo elgg_view('page/elements/comments_block', array(
+ 'subtypes' => array('page', 'page_top'),
+ 'owner_guid' => elgg_get_page_owner_guid(),
+));