aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-07-09 17:55:47 +0000
committerben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-07-09 17:55:47 +0000
commit80faac618234400e019a570f4376567b1073d661 (patch)
treefb9a70d854b35dddd0a8eb58eb00c8ecb59c1a7c
parentd238ef94c66d487fef38fee8d5243f1d15d39978 (diff)
downloadelgg-80faac618234400e019a570f4376567b1073d661.tar.gz
elgg-80faac618234400e019a570f4376567b1073d661.tar.bz2
Added profile submenu
git-svn-id: https://code.elgg.org/elgg/trunk@1375 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r--mod/profile/languages/en.php3
-rw-r--r--mod/profile/start.php20
2 files changed, 16 insertions, 7 deletions
diff --git a/mod/profile/languages/en.php b/mod/profile/languages/en.php
index 4da311ab1..be70f4243 100644
--- a/mod/profile/languages/en.php
+++ b/mod/profile/languages/en.php
@@ -30,6 +30,9 @@
'profile:profilepicturecroppingtool' => "Profile picture cropping tool",
'profile:createicon:instructions' => "Click and drag a square below to match how you want your picture cropped. A preview of your cropped picture will appear in the box on the right. When you are happy with the preview, click 'Create your avatar'. This cropped image will be used throughout the site as your avatar. ",
+ 'profile:editdetails' => "Edit details",
+ 'profile:editicon' => "Edit profile icon",
+
'profile:aboutme' => "About me",
'profile:description' => "About me",
'profile:location' => "Location",
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())
{