From 80faac618234400e019a570f4376567b1073d661 Mon Sep 17 00:00:00 2001 From: ben Date: Wed, 9 Jul 2008 17:55:47 +0000 Subject: Added profile submenu git-svn-id: https://code.elgg.org/elgg/trunk@1375 36083f99-b078-4883-b0ff-0f9b5a30f544 --- mod/profile/start.php | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) (limited to 'mod/profile/start.php') diff --git a/mod/profile/start.php b/mod/profile/start.php index 80901659f..aa42374fc 100644 --- a/mod/profile/start.php +++ b/mod/profile/start.php @@ -27,13 +27,13 @@ register_entity_url_handler('profile_url','user','all'); // Set up menu for logged in users - if (isloggedin()) { - add_menu(elgg_echo('profile'), $CONFIG->wwwroot . "pg/profile/" . $_SESSION['user']->username,array( - menu_item(elgg_echo('profile:yours'),$CONFIG->wwwroot . "pg/profile/" . $_SESSION['user']->username), - menu_item(elgg_echo('profile:edit'),$CONFIG->wwwroot."mod/profile/edit.php"), - menu_item(elgg_echo('profile:editicon'),$CONFIG->wwwroot."mod/profile/editicon.php"), - ),'profile'); - } + // if (isloggedin()) { + // add_menu(elgg_echo('profile'), $CONFIG->wwwroot . "pg/profile/" . $_SESSION['user']->username,array( + // menu_item(elgg_echo('profile:yours'),$CONFIG->wwwroot . "pg/profile/" . $_SESSION['user']->username), + // menu_item(elgg_echo('profile:edit'),$CONFIG->wwwroot."mod/profile/edit.php"), + // menu_item(elgg_echo('profile:editicon'),$CONFIG->wwwroot."mod/profile/editicon.php"), + // ),'profile'); + // } // For now, we'll hard code the profile items as follows: // TODO make this user configurable @@ -62,6 +62,12 @@ if (get_context() == "profile") extend_view('canvas_header/submenu','profile/submenu'); + //add submenu options + if (get_context() == "profile") { + add_submenu_item("Edit Details", $CONFIG->wwwroot . "mod/profile/edit.php"); + add_submenu_item("Edit profile picture", $CONFIG->wwwroot . "mod/profile/editicon.php"); + } + // Extend context menu with admin links if (isadminloggedin()) { -- cgit v1.2.3