aboutsummaryrefslogtreecommitdiff
path: root/mod/profile/views/default/profile/profilelinks.php
blob: 5873fe210a49e2bceec3cc71f8cfb76d59f4434b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php

	/**
	 * Elgg profile links
	 * We need to make sure that the correct links display depending on whether you are looking at your own 
	 * profile or someone else's
	 * 
	 * @package ElggProfile
	 * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
	 * @author Curverider Ltd <info@elgg.com>
	 * @copyright Curverider Ltd 2008
	 * @link http://elgg.com/
	 * 
	 * @uses $vars['entity'] The user entity. If none specified, the current user is assumed. 
	 */

?>

<?php

    //check to see if the user is looking at their own profile
    if($_SESSION['user']->guid == page_owner()){

        echo "<div id=\"profile_menu_wrapper\">"; //start the wrapper div
	    echo elgg_view("profile/menu/actions",$vars);//grab action links such as make friend
	    echo elgg_view("profile/menu/linksownpage",$vars); // an different view for user's own profile
	    echo "</div>"; //close wrapper div 
	    
    } else {
        
        echo "<div id=\"profile_menu_wrapper\">"; //start the wrapper div
        echo elgg_view("profile/menu/actions",$vars); //grab action links such as make friend
	    echo elgg_view("profile/menu/links",$vars); //passive links to items such as user blog etc
	    echo "</div>"; //close wrapper div 
	    
    }

?>