From abf3fcae3f90b4c52e40d3ef8bb11f92c7a03d1c Mon Sep 17 00:00:00 2001 From: cash Date: Sun, 19 Dec 2010 01:44:33 +0000 Subject: rough widget profile plugin git-svn-id: http://code.elgg.org/elgg/trunk@7676 36083f99-b078-4883-b0ff-0f9b5a30f544 --- mod/profile/start.php | 30 +++++++++++++----------------- 1 file changed, 13 insertions(+), 17 deletions(-) (limited to 'mod/profile/start.php') diff --git a/mod/profile/start.php b/mod/profile/start.php index d7dd0e3e0..2f817b644 100644 --- a/mod/profile/start.php +++ b/mod/profile/start.php @@ -70,25 +70,21 @@ function profile_page_handler($page) { $action = $page[1]; } - switch ($action) { - case 'edit': - // use for the core profile edit page - require $CONFIG->path . 'pages/profile/edit.php'; - return; - break; - - default: - if (isset($page[1])) { - $section = $page[1]; - } else { - $section = 'activity'; - } - $content = profile_get_user_profile_html($user, $section); - $content = elgg_view_layout('one_column', array('content' => $content)); - break; + if ($action == 'edit') { + // use for the core profile edit page + require $CONFIG->path . 'pages/profile/edit.php'; + return; } - echo elgg_view_page($title, $content); + // main profile page + $params = array( + 'box' => elgg_view('profile/box'), + 'num_columns' => 3, + ); + $content = elgg_view_layout('widgets', $params); + + $body = elgg_view_layout('one_column', array('content' => $content)); + echo elgg_view_page($title, $body); } /** -- cgit v1.2.3