aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-10-30 21:48:24 +0000
committerewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-10-30 21:48:24 +0000
commitc27eac2d2a970e76a1204757bbe15da8efb2870c (patch)
tree7f524d3ee95391163293d9f77a945e2915c3e8ac /engine
parentf49fdf4e1c80fe5bde922c25bdd6ca0e2c912ddb (diff)
downloadelgg-c27eac2d2a970e76a1204757bbe15da8efb2870c.tar.gz
elgg-c27eac2d2a970e76a1204757bbe15da8efb2870c.tar.bz2
Refs #1439: Using new page_owner functions in all of core
git-svn-id: http://code.elgg.org/elgg/trunk@7140 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/group.php6
-rw-r--r--engine/lib/users.php10
-rw-r--r--engine/lib/views.php2
3 files changed, 9 insertions, 9 deletions
diff --git a/engine/lib/group.php b/engine/lib/group.php
index 8c68e0aca..ed7aa504a 100644
--- a/engine/lib/group.php
+++ b/engine/lib/group.php
@@ -201,7 +201,7 @@ $order_by = "", $limit = 10, $offset = 0, $count = FALSE) {
$container_guid = (int)$group_guid;
if ($container_guid == 0) {
- $container_guid = page_owner();
+ $container_guid = elgg_get_page_owner_guid();
}
$where = array();
@@ -309,7 +309,7 @@ $order_by = "", $site_guid = 0, $count = false) {
$container_guid = (int)$group_guid;
if ($container_guid == 0) {
- $container_guid = page_owner();
+ $container_guid = elgg_get_page_owner_guid();
}
$where = array();
@@ -583,7 +583,7 @@ function group_gatekeeper($forward = true) {
$allowed = true;
$url = '';
- if ($group = page_owner_entity()) {
+ if ($group = elgg_get_page_owner()) {
if ($group instanceof ElggGroup) {
$url = $group->getURL();
if (
diff --git a/engine/lib/users.php b/engine/lib/users.php
index e980ee6f8..6c6e51d4d 100644
--- a/engine/lib/users.php
+++ b/engine/lib/users.php
@@ -1243,7 +1243,7 @@ function friends_page_handler($page_elements) {
if (isset($page_elements[0]) && $user = get_user_by_username($page_elements[0])) {
set_page_owner($user->getGUID());
}
- if (get_loggedin_userid() == page_owner()) {
+ if (get_loggedin_userid() == elgg_get_page_owner_guid()) {
// disabled for now as we no longer use friends collections (replaced by shared access)
// collections_submenu_items();
}
@@ -1261,7 +1261,7 @@ function friends_of_page_handler($page_elements) {
if (isset($page_elements[0]) && $user = get_user_by_username($page_elements[0])) {
set_page_owner($user->getGUID());
}
- if (get_loggedin_userid() == page_owner()) {
+ if (get_loggedin_userid() == elgg_get_page_owner_guid()) {
// disabled for now as we no longer use friends collections (replaced by shared access)
// collections_submenu_items();
}
@@ -1284,7 +1284,7 @@ function collections_page_handler($page_elements) {
} else {
if ($user = get_user_by_username($page_elements[0])) {
set_page_owner($user->getGUID());
- if (get_loggedin_userid() == page_owner()) {
+ if (get_loggedin_userid() == elgg_get_page_owner_guid()) {
collections_submenu_items();
}
require_once(dirname(dirname(dirname(__FILE__))) . "/pages/friends/collections.php");
@@ -1401,10 +1401,10 @@ function users_pagesetup() {
// || get_context() == "collections") { - disabled as we no longer use collections
add_submenu_item(elgg_echo('friends'), $CONFIG->wwwroot . "pg/friends/"
- . page_owner_entity()->username);
+ . elgg_get_page_owner()->username);
add_submenu_item(elgg_echo('friends:of'), $CONFIG->wwwroot . "pg/friendsof/"
- . page_owner_entity()->username);
+ . elgg_get_page_owner()->username);
if (is_plugin_enabled('members')) {
add_submenu_item(elgg_echo('members:browse'), $CONFIG->wwwroot . "mod/members/index.php");
diff --git a/engine/lib/views.php b/engine/lib/views.php
index 755fa9da2..d8564c5e3 100644
--- a/engine/lib/views.php
+++ b/engine/lib/views.php
@@ -283,7 +283,7 @@ function elgg_view($view, $vars = array(), $bypass = false, $debug = false, $vie
// Load page owner variables into $vars
if (is_callable('page_owner')) {
- $vars['page_owner'] = page_owner();
+ $vars['page_owner'] = elgg_get_page_owner_guid();
} else {
$vars['page_owner'] = -1;
}