diff options
author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-06-18 21:16:00 +0000 |
---|---|---|
committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-06-18 21:16:00 +0000 |
commit | 677e155a31776c63fbd5701f76302e422a0dadb9 (patch) | |
tree | 23181592af997ded7980203bf6f87078c1f7fbfe /friends/index.php | |
parent | f2aa2c6980460261f27bf01d3e074aa9b2d4bd5d (diff) | |
download | elgg-677e155a31776c63fbd5701f76302e422a0dadb9.tar.gz elgg-677e155a31776c63fbd5701f76302e422a0dadb9.tar.bz2 |
Merged friends pages fixes in r6501:6503 from 1.7 to trunk.
git-svn-id: http://code.elgg.org/elgg/trunk@6515 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'friends/index.php')
-rw-r--r-- | friends/index.php | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/friends/index.php b/friends/index.php index 23dd098d5..b7f0a2a75 100644 --- a/friends/index.php +++ b/friends/index.php @@ -8,15 +8,19 @@ * @link http://elgg.org/ */ -if (!$owner = page_owner_entity()) { +$owner = page_owner_entity(); +if (!$owner) { gatekeeper(); - set_page_owner($_SESSION['user']->getGUID()); - $owner = $_SESSION['user']; + set_page_owner(get_loggedin_userid()); + $owner = page_owner_entity(); } -$friends = sprintf(elgg_echo("friends:owned"),$owner->name); -$area1 = elgg_view_title($friends); -$area2 = "<div class='members_list'>".list_entities_from_relationship('friend',$owner->getGUID(),false,'user','',0,10,false)."</div>"; -$body = elgg_view_layout('one_column_with_sidebar', $area1 . $area2); +$title = sprintf(elgg_echo("friends:owned"), $owner->name); -page_draw($friends, $body); +$content = elgg_view_title($title); + +$content .= "<div class='members_list'>" . list_entities_from_relationship('friend', $owner->getGUID(), FALSE, 'user', '', 0, 10, FALSE) . "</div>"; + +$body = elgg_view_layout('one_column_with_sidebar', $content); + +page_draw($title, $body); |