diff options
Diffstat (limited to 'mod')
54 files changed, 151 insertions, 79 deletions
diff --git a/mod/blog/start.php b/mod/blog/start.php index 92ddf65c8..365a21cfa 100644 --- a/mod/blog/start.php +++ b/mod/blog/start.php @@ -155,7 +155,11 @@ function blog_page_handler($page) { $content = elgg_view('navigation/breadcrumbs') . $content_info['content']; - $body = elgg_view_layout('one_column_with_sidebar', $content, $sidebar); + $params = array( + 'content' => $content, + 'sidebar' => $sidebar, + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body); } diff --git a/mod/bookmarks/bookmarklet.php b/mod/bookmarks/bookmarklet.php index 8e30f52dd..7a2f1a16f 100644 --- a/mod/bookmarks/bookmarklet.php +++ b/mod/bookmarks/bookmarklet.php @@ -28,8 +28,9 @@ $area2 .= elgg_view('bookmarks/bookmarklet', array('pg_owner' => $page_owner)); // if logged in, get the bookmarklet $area3 = elgg_view("bookmarks/bookmarklet"); -// Format page -$body = elgg_view_layout('one_column_with_sidebar', $area1.$area2, $area3); +// Format +$content = $area1 . $area2 . $area3; +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); // Draw it echo elgg_view_page(elgg_echo('bookmarks:bookmarklet'),$body);
\ No newline at end of file diff --git a/mod/bookmarks/start.php b/mod/bookmarks/start.php index b0a2369d3..95922cd22 100644 --- a/mod/bookmarks/start.php +++ b/mod/bookmarks/start.php @@ -95,7 +95,11 @@ function bookmarks_page_handler($page) { $sidebar = elgg_view('bookmarks/sidebar', array('object_type' => 'bookmarks')); $content = elgg_echo("bookmarks:unknown_user"); - $body = elgg_view_layout('one_column_with_sidebar', $content, $sidebar); + $params = array( + 'content' => $content, + 'sidebar' => $sidebar, + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page(elgg_echo("bookmarks:user", array(elgg_get_page_owner()->name)), $body); return FALSE; @@ -239,7 +243,11 @@ function bookmarks_page_handler($page) { } $content = $header . $content; - $body = elgg_view_layout('one_column_with_sidebar', $content, $sidebar); + $params = array( + 'content' => $content, + 'sidebar' => $sidebar, + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page(elgg_echo("bookmarks:user", array(elgg_get_page_owner()->name)), $body); return TRUE; diff --git a/mod/diagnostics/index.php b/mod/diagnostics/index.php index 657915e66..c7a5cd4b1 100644 --- a/mod/diagnostics/index.php +++ b/mod/diagnostics/index.php @@ -11,14 +11,14 @@ admin_gatekeeper(); elgg_set_context('admin'); // system diagnostics -$body = elgg_view_title(elgg_echo('diagnostics')); -$body .= "<div class='admin_settings diagnostics'>"; -$body .= elgg_view('page_elements/content', array('body' => +$content = elgg_view_title(elgg_echo('diagnostics')); +$content .= "<div class='admin_settings diagnostics'>"; +$content .= elgg_view('page_elements/content', array('body' => "<h3>".elgg_echo('diagnostics:report')."</h3>".elgg_echo('diagnostics:description') . elgg_view('diagnostics/forms/download')) ); // unit tests -$body .= "<h3>".elgg_echo('diagnostics:unittester')."</h3>"; +$content .= "<h3>".elgg_echo('diagnostics:unittester')."</h3>"; $test_body = "<p>" . elgg_echo('diagnostics:unittester:description') . "</p>"; $test_body .= "<p>" . elgg_echo('diagnostics:unittester:warning') . "</p>"; @@ -32,9 +32,10 @@ if (isset($CONFIG->debug)) { $test_body .= elgg_echo('diagnostics:unittester:debug'); } -$body .= elgg_view('page_elements/content', array( +$content .= elgg_view('page_elements/content', array( 'body' => $test_body) ); -$body .= "</div>"; -// create page -echo elgg_view_page(elgg_echo('diagnostics'), elgg_view_layout("one_column_with_sidebar", $body)); +$content .= "</div>"; + +$body = elgg_view_layout("one_column_with_sidebar", array('content' => $content)); +echo elgg_view_page(elgg_echo('diagnostics'), $body); diff --git a/mod/ecml/start.php b/mod/ecml/start.php index 82bea88ae..0d60dd1a5 100644 --- a/mod/ecml/start.php +++ b/mod/ecml/start.php @@ -87,7 +87,7 @@ function ecml_init() { function ecml_help_page_handler($page) { if (!isset($page[0]) || empty($page[0])) { $content = elgg_view('ecml/help'); - $body = elgg_view_layout('one_column_with_sidebar', $content); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); echo elgg_view_page(elgg_echo('ecml:help'), $body); } else { // asking for detailed help about a keyword @@ -98,7 +98,7 @@ function ecml_help_page_handler($page) { echo $content; exit; } else { - $body = elgg_view_layout('one_column_with_sidebar', $content); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); echo elgg_view_page(elgg_echo('ecml:help'), $body); } } @@ -183,7 +183,7 @@ function ecml_admin_page_handler($page) { admin_gatekeeper(); elgg_set_context('admin'); $content = elgg_view('ecml/admin/ecml_admin'); - $body = elgg_view_layout('one_column_with_sidebar', $content); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); echo elgg_view_page(elgg_echo('ecml:admin'), $body); } diff --git a/mod/file/edit.php b/mod/file/edit.php index 5c2afc120..961332420 100644 --- a/mod/file/edit.php +++ b/mod/file/edit.php @@ -34,5 +34,5 @@ $title = elgg_echo('file:edit'); $area1 = elgg_view_title($title); $area1 .= elgg_view("file/upload", array('entity' => $file)); -$body = elgg_view_layout('one_column_with_sidebar', $area1); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1)); echo elgg_view_page($title, $body); diff --git a/mod/file/friends.php b/mod/file/friends.php index 895105480..32eeeffd8 100644 --- a/mod/file/friends.php +++ b/mod/file/friends.php @@ -34,7 +34,11 @@ $area3 = elgg_view('annotation/latest_comments', array('comments' => $comments)); $content = "<div class='files'>".$area1.$area2."</div>"; - $body = elgg_view_layout('one_column_with_sidebar', $content, $area3); + $params = array( + 'content' => $content, + 'sidebar' => $area3 + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body); ?>
\ No newline at end of file diff --git a/mod/file/index.php b/mod/file/index.php index 21d573b2b..65144b7bb 100644 --- a/mod/file/index.php +++ b/mod/file/index.php @@ -40,7 +40,12 @@ $area3 = elgg_view('annotation/latest_comments', array('comments' => $comments)); $content = "<div class='files'>".$area1.$area2."</div>"; - $body = elgg_view_layout('one_column_with_sidebar', $content, $area3); + + $params = array( + 'content' => $content, + 'sidebar' => $area3 + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body); ?>
\ No newline at end of file diff --git a/mod/file/search.php b/mod/file/search.php index b0120d932..8dd4669a9 100644 --- a/mod/file/search.php +++ b/mod/file/search.php @@ -92,7 +92,7 @@ $content = "<div class='files'>".$area1.$area2."</div>"; - $body = elgg_view_layout('one_column_with_sidebar', $content); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); echo elgg_view_page($title, $body); diff --git a/mod/file/upload.php b/mod/file/upload.php index 975b8e66a..2040c7240 100644 --- a/mod/file/upload.php +++ b/mod/file/upload.php @@ -17,7 +17,7 @@ $container_guid = elgg_get_page_owner_guid(); $area1 = elgg_view_title($title = elgg_echo('file:upload')); $area1 .= elgg_view("file/upload", array('container_guid' => $container_guid)); - $body = elgg_view_layout('one_column_with_sidebar', $area1); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1)); echo elgg_view_page(elgg_echo("file:upload"), $body); diff --git a/mod/file/world.php b/mod/file/world.php index a3d78ef7b..bd6c2b859 100644 --- a/mod/file/world.php +++ b/mod/file/world.php @@ -31,7 +31,10 @@ $area3 = elgg_view('annotation/latest_comments', array('comments' => $comments)); $content = "<div class='files'>".$area1.$area2."</div>"; - - $body = elgg_view_layout('one_column_with_sidebar', $content, $area3); + $params = array( + 'content' => $content, + 'sidebar' => $area3 + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body); diff --git a/mod/groups/activity.php b/mod/groups/activity.php index 487af7e8d..57678be6d 100644 --- a/mod/groups/activity.php +++ b/mod/groups/activity.php @@ -51,7 +51,7 @@ $area1 .= elgg_view_title(elgg_echo('groups:activity')); $area1 .= elgg_view("group_activity/extend");
$area1 .= "<div class='group_listings hide_comments'>".$river_items."</div>";
$title = elgg_echo("groups:activity", array(elgg_get_page_owner()->name));
-$body = elgg_view_layout('one_column_with_sidebar', $area1);
+$body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1));
// Finally draw the page
echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/groups/addtopic.php b/mod/groups/addtopic.php index 85bef8ae5..008f34d9e 100644 --- a/mod/groups/addtopic.php +++ b/mod/groups/addtopic.php @@ -14,7 +14,8 @@ if (!(elgg_get_page_owner() instanceof ElggGroup)) forward(); // sort the display $area2 = elgg_view("forms/forums/addtopic"); -$body = elgg_view_layout('one_column_with_sidebar', $area1.$area2); +$content = $area1 . $area2; +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); // Display page echo elgg_view_page(elgg_echo('groups:addtopic'),$body);
\ No newline at end of file diff --git a/mod/groups/all.php b/mod/groups/all.php index 1e7b93b65..cf1a483b1 100644 --- a/mod/groups/all.php +++ b/mod/groups/all.php @@ -59,7 +59,9 @@ $area1 .= elgg_view('page_elements/content_header', array('context' => "everyone", 'type' => 'groups', 'new_link' => "pg/groups/new")); } $area1 .= elgg_view("groups/group_sort_menu", array("count" => $group_count, "filter" => $filter)) . $objects; - $body = elgg_view_layout('one_column_with_sidebar', $area1, $area2); + + $content = $area1 . $area2; + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $content)); // Finally draw the page echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/groups/edit.php b/mod/groups/edit.php index ddaec0060..59064b7d8 100644 --- a/mod/groups/edit.php +++ b/mod/groups/edit.php @@ -23,7 +23,7 @@ $body .= elgg_echo('groups:noaccess'); } - $body = elgg_view_layout('one_column_with_sidebar', $body); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); echo elgg_view_page($title, $body); ?>
\ No newline at end of file diff --git a/mod/groups/edittopic.php b/mod/groups/edittopic.php index 03d220af0..73730904f 100644 --- a/mod/groups/edittopic.php +++ b/mod/groups/edittopic.php @@ -19,7 +19,7 @@ $topic = get_entity((int) get_input('topic')); // sort the display $area2 = elgg_view("forms/forums/edittopic", array('entity' => $topic)); -$body = elgg_view_layout('one_column_with_sidebar', $area2); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $area2)); // Display page echo elgg_view_page(elgg_echo('groups:edittopic'),$body);
\ No newline at end of file diff --git a/mod/groups/forum.php b/mod/groups/forum.php index 376098f80..55f7dd95e 100644 --- a/mod/groups/forum.php +++ b/mod/groups/forum.php @@ -37,7 +37,7 @@ $area1 = elgg_view('navigation/breadcrumbs'); $area1 .= elgg_view("forum/topics", array('topics' => $topics, 'group_guid' => $group_guid)); elgg_set_context('groups'); -$body = elgg_view_layout('one_column_with_sidebar', $area1); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1)); $title = elgg_echo('item:object:groupforumtopic'); diff --git a/mod/groups/groupprofile.php b/mod/groups/groupprofile.php index bb577fde2..e7daddb43 100644 --- a/mod/groups/groupprofile.php +++ b/mod/groups/groupprofile.php @@ -35,15 +35,20 @@ } else { $area2 .= elgg_view('groups/closedmembership', array('entity' => $group, 'user' => get_loggedin_user(), 'full' => true)); } - - $body = elgg_view_layout('one_column_with_sidebar', $area1.$area2, $area3); + + $content = $area1 . $area2; + $params = array( + 'content' => $content, + 'sidebar' => $area3 + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); } else { $title = elgg_echo('groups:notfound'); $area2 = elgg_view_title($title); $area2 .= "<p class='margin_top'>".elgg_echo('groups:notfound:details')."</p>"; - $body = elgg_view_layout('one_column_with_sidebar', $area2); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area2)); } // Finally draw the page diff --git a/mod/groups/index.php b/mod/groups/index.php index 457d2eb55..a8c81b27e 100644 --- a/mod/groups/index.php +++ b/mod/groups/index.php @@ -20,7 +20,7 @@ elgg_pop_context(); $area1 .= $objects; - $body = elgg_view_layout('one_column_with_sidebar', $area1); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1)); // Finally draw the page echo elgg_view_page($title, $body); diff --git a/mod/groups/invitations.php b/mod/groups/invitations.php index 837534f99..6a187a8fa 100644 --- a/mod/groups/invitations.php +++ b/mod/groups/invitations.php @@ -26,6 +26,6 @@ if ($user) { $area2 .= elgg_echo("groups:noaccess"); } -$body = elgg_view_layout('one_column_with_sidebar', $area2); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1)); echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/groups/invite.php b/mod/groups/invite.php index 48dfea58b..acc54b15d 100644 --- a/mod/groups/invite.php +++ b/mod/groups/invite.php @@ -24,7 +24,7 @@ $area2 .= elgg_echo("groups:noaccess"); } - $body = elgg_view_layout('one_column_with_sidebar', $area1.$area2); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1 . $area2)); echo elgg_view_page($title, $body); ?>
\ No newline at end of file diff --git a/mod/groups/membership.php b/mod/groups/membership.php index dd5fd675b..8eea0b6bb 100644 --- a/mod/groups/membership.php +++ b/mod/groups/membership.php @@ -27,7 +27,7 @@ elgg_pop_context(); $area2 .= $objects; - $body = elgg_view_layout('one_column_with_sidebar', $area1.$area2); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1. $area2)); // Finally draw the page echo elgg_view_page($title, $body); diff --git a/mod/groups/membershipreq.php b/mod/groups/membershipreq.php index e37825e74..4ce2a6b7d 100644 --- a/mod/groups/membershipreq.php +++ b/mod/groups/membershipreq.php @@ -26,7 +26,7 @@ $area2 .= elgg_echo("groups:noaccess"); } - $body = elgg_view_layout('one_column_with_sidebar', $area1.$area2); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1 . $area2)); echo elgg_view_page($title, $body); ?>
\ No newline at end of file diff --git a/mod/groups/new.php b/mod/groups/new.php index 4f8179e58..84d1539af 100644 --- a/mod/groups/new.php +++ b/mod/groups/new.php @@ -14,7 +14,7 @@ $area2 = elgg_view_title($title); $area2 .= elgg_view("forms/groups/edit"); - $body = elgg_view_layout('one_column_with_sidebar', $area1.$area2); + $body = elgg_view_layout('one_column_with_sidebar', array('content' => $area1 . $area2)); echo elgg_view_page($title, $body); ?>
\ No newline at end of file diff --git a/mod/groups/topicposts.php b/mod/groups/topicposts.php index 0673156f1..fe9b85cec 100644 --- a/mod/groups/topicposts.php +++ b/mod/groups/topicposts.php @@ -25,7 +25,7 @@ // Display them $area2 = elgg_view("forum/viewposts", array('entity' => $topic)); - $body = elgg_view_layout("one_column_with_sidebar", $area2); + $body = elgg_view_layout("one_column_with_sidebar", array('content' => $area2)); // Display page echo elgg_view_page($topic->title,$body); diff --git a/mod/invitefriends/index.php b/mod/invitefriends/index.php index 4b7637c97..7b4c34562 100644 --- a/mod/invitefriends/index.php +++ b/mod/invitefriends/index.php @@ -14,6 +14,6 @@ elgg_set_context('friends'); set_page_owner(get_loggedin_userid()); $body = elgg_view('invitefriends/form'); -$body = elgg_view_layout('one_column_with_sidebar', $body); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); echo elgg_view_page(elgg_echo('friends:invite'), $body); diff --git a/mod/members/index.php b/mod/members/index.php index 5a461d5e8..a4f21da13 100644 --- a/mod/members/index.php +++ b/mod/members/index.php @@ -74,7 +74,11 @@ switch($filter){ $area2 .= elgg_view('page_elements/content', array('body' => elgg_view("members/members_navigation", array("count" => $members, "filter" => $filter)) . "<div class='members_list'>".$filter_content."</div>", 'subclass' => 'members')); //select the correct canvas area -$body = elgg_view_layout("one_column_with_sidebar", $area2, $area1); +$params = array( + 'content' => $area2, + 'sidebar' => $area1 +); +$body = elgg_view_layout("one_column_with_sidebar", $params); // Display page echo elgg_view_page(elgg_echo('members:members', array($page_owner->name)), $body);
\ No newline at end of file diff --git a/mod/messages/index.php b/mod/messages/index.php index 16049f918..5b79a54ae 100644 --- a/mod/messages/index.php +++ b/mod/messages/index.php @@ -42,7 +42,7 @@ $area2 .= elgg_view("messages/forms/view",array('entity' => $messages, 'page_vie //$area3 = elgg_view("messages/menu_options", array('context' => 'inbox')); // format -$body = elgg_view_layout("one_column_with_sidebar", $area2); +$body = elgg_view_layout("one_column_with_sidebar", array('content' => $area2)); // Draw page diff --git a/mod/messages/read.php b/mod/messages/read.php index 740011c3e..4e404de5c 100644 --- a/mod/messages/read.php +++ b/mod/messages/read.php @@ -48,7 +48,11 @@ $content = elgg_view("messages/messages",array( $sidebar = elgg_view("messages/menu_options"); -$body = elgg_view_layout("one_column_with_sidebar", $content, $sidebar); +$params = array( + 'content' => $content, + 'sidebar' => $sidebar +); +$body = elgg_view_layout("one_column_with_sidebar", $params); // Display page echo elgg_view_page(elgg_echo('messages:message'), $body);
\ No newline at end of file diff --git a/mod/messages/send.php b/mod/messages/send.php index 359c38ae1..3e1baa496 100644 --- a/mod/messages/send.php +++ b/mod/messages/send.php @@ -32,7 +32,11 @@ $area2 .= elgg_view("messages/forms/send",array('friends' => $friends)); $area3 = elgg_view("messages/menu_options"); // Format -$body = elgg_view_layout("one_column_with_sidebar", $area2, $area3); +$params = array( + 'content' => $area2, + 'sidebar' => $area3 +); +$body = elgg_view_layout("one_column_with_sidebar", $params); // Draw page echo elgg_view_page(elgg_echo('messages:send', array($page_owner->name)), $body);
\ No newline at end of file diff --git a/mod/messages/sent.php b/mod/messages/sent.php index bb0746c80..89771d6b7 100644 --- a/mod/messages/sent.php +++ b/mod/messages/sent.php @@ -34,7 +34,7 @@ $area2 .= "<div class='content_header_options'><a class='action_button' href='". $area2 .= elgg_view("messages/forms/view",array('entity' => $messages, 'page_view' => "sent", 'limit' => $limit, 'offset' => $offset)); // Format -$body = elgg_view_layout("one_column_with_sidebar", $area2); +$body = elgg_view_layout("one_column_with_sidebar", array('content' => $area2)); // Draw page echo elgg_view_page(elgg_echo('messages:sentMessages', array($page_owner->name)), $body); diff --git a/mod/notifications/groups.php b/mod/notifications/groups.php index 9b176955a..10e320032 100644 --- a/mod/notifications/groups.php +++ b/mod/notifications/groups.php @@ -30,7 +30,7 @@ $body = elgg_view('input/form',array( )); // Insert it into the correct canvas layout -$body = elgg_view_layout('one_column_with_sidebar', $body); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); echo elgg_view_page(elgg_echo('notifications:subscriptions:changesettings:groups'), $body); diff --git a/mod/notifications/index.php b/mod/notifications/index.php index 209de9cd2..e0565959d 100644 --- a/mod/notifications/index.php +++ b/mod/notifications/index.php @@ -28,7 +28,7 @@ if ($people_ents = elgg_get_entities_from_relationship(array('relationship' => ' $body = elgg_view('notifications/subscriptions/form', array('people' => $people)); // Insert it into the correct canvas layout -$body = elgg_view_layout('one_column_with_sidebar', $body); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); echo elgg_view_page(elgg_echo('notifications:subscriptions:changesettings'), $body); diff --git a/mod/pages/edit.php b/mod/pages/edit.php index d404e0433..dc290ea7d 100644 --- a/mod/pages/edit.php +++ b/mod/pages/edit.php @@ -31,6 +31,6 @@ if ($pages && ($pages->canEdit())) { $body .= elgg_echo("pages:noaccess"); } -$body = elgg_view_layout('one_column_with_sidebar', $body); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/pages/history.php b/mod/pages/history.php index d39bf7ae0..d40dfaeb8 100644 --- a/mod/pages/history.php +++ b/mod/pages/history.php @@ -35,6 +35,10 @@ $content.= list_annotations($page_guid, 'page', $limit, false); pages_set_navigation_parent($pages); $sidebar = elgg_view('pages/sidebar/tree'); -$body = elgg_view_layout('one_column_with_sidebar', $content, $sidebar); +$params = array( + 'content' => $content, + 'sidebar' => $sidebar +); +$body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body); diff --git a/mod/pages/index.php b/mod/pages/index.php index 31f76f625..1d84587d5 100644 --- a/mod/pages/index.php +++ b/mod/pages/index.php @@ -44,7 +44,7 @@ $welcome_message = elgg_get_entities(array('types' => 'object', 'subtypes' => 'p $body = elgg_view_title($title); $body .= elgg_view("pages/welcome", array('entity' => $welcome_message)); $body .= $objects; -$body = elgg_view_layout('one_column_with_sidebar', $body); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); // Finally draw the page echo elgg_view_page($title, $body); diff --git a/mod/pages/new.php b/mod/pages/new.php index af1443d0a..2175572b2 100644 --- a/mod/pages/new.php +++ b/mod/pages/new.php @@ -34,6 +34,10 @@ $title = elgg_echo("pages:new"); $area2 .= elgg_view_title($title); $area2 .= elgg_view("forms/pages/edit"); -$body = elgg_view_layout('one_column_with_sidebar', $area2, $area1); +$params = array( + 'content' => $area2, + 'sidebar' => $area1 +); +$body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/pages/view.php b/mod/pages/view.php index 83b8d69c1..6996c44e0 100644 --- a/mod/pages/view.php +++ b/mod/pages/view.php @@ -54,7 +54,10 @@ $body .= elgg_view_comments($pages); pages_set_navigation_parent($pages); $sidebar = elgg_view('pages/sidebar/tree'); -$body = elgg_view_layout('one_column_with_sidebar', $body, $sidebar); +$params = array( + 'content' => $body, + 'sidebar' => $sidebar +); +$body = elgg_view_layout('one_column_with_sidebar', $params); -// Finally draw the page echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/pages/welcome.php b/mod/pages/welcome.php index 7a2a43abd..7db649253 100644 --- a/mod/pages/welcome.php +++ b/mod/pages/welcome.php @@ -30,6 +30,10 @@ $title = elgg_echo("pages:welcome"); $area2 .= elgg_view_title($title); $area2 .= elgg_view("forms/pages/editwelcome", array('entity' => $welcome_message, 'owner' => $page_owner)); -$body = elgg_view_layout('one_column_with_sidebar', $area2, $area1); +$params = array( + 'content' => $area2, + 'sidebar' => $area1 +); +$body = elgg_view_layout('one_column_with_sidebar', $params); echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/pages/world.php b/mod/pages/world.php index 35a17b1e6..d258ba157 100644 --- a/mod/pages/world.php +++ b/mod/pages/world.php @@ -38,7 +38,7 @@ elgg_pop_context(); $body = elgg_view_title($title); $body .= $objects; -$body = elgg_view_layout('one_column_with_sidebar', $body); +$body = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); // Finally draw the page echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/profile/edit.php b/mod/profile/edit.php index 12ce8564a..bef1cc094 100644 --- a/mod/profile/edit.php +++ b/mod/profile/edit.php @@ -33,8 +33,6 @@ $area1 .= elgg_view("profile/edit",array('entity' => $user)); elgg_set_context('profile_edit'); -// get the required canvas area -$body = elgg_view_layout("one_column_with_sidebar", $area1); +$body = elgg_view_layout("one_column_with_sidebar", array('content' => $area1)); -// Draw the page -echo elgg_view_page(elgg_echo("profile:edit"),$body); +echo elgg_view_page(elgg_echo("profile:edit"), $body); diff --git a/mod/profile/editicon.php b/mod/profile/editicon.php index 4c19937b2..85b06cc17 100644 --- a/mod/profile/editicon.php +++ b/mod/profile/editicon.php @@ -33,7 +33,7 @@ $area1 .= elgg_view("profile/edit_icon", array('user' => $user)); elgg_set_context('profile_edit'); // Get the form and correct canvas area -$body = elgg_view_layout("one_column_with_sidebar", $area1); +$body = elgg_view_layout("one_column_with_sidebar", array('content' => $area1)); // Draw the page echo elgg_view_page(elgg_echo("profile:editicon"), $body); diff --git a/mod/profile/index.php b/mod/profile/index.php index bf47d670c..7c9c0a3cc 100644 --- a/mod/profile/index.php +++ b/mod/profile/index.php @@ -45,5 +45,5 @@ if ($user = get_user_by_username($username)) { $body = elgg_echo("profile:notfound"); $title = elgg_echo("profile"); } -$body = elgg_view_layout("one_column", $body); +$body = elgg_view_layout("one_column", array('content' => $body)); echo elgg_view_page($title, $body);
\ No newline at end of file diff --git a/mod/profile/start.php b/mod/profile/start.php index 6e9a43a68..1ba2e6dc5 100644 --- a/mod/profile/start.php +++ b/mod/profile/start.php @@ -145,7 +145,7 @@ function profile_page_handler($page) { } $content = profile_get_user_edit_content($user, $page); - $content = elgg_view_layout($layout, $content); + $content = elgg_view_layout($layout, array('content' => $content)); break; default: @@ -156,7 +156,7 @@ function profile_page_handler($page) { $section = 'activity'; } $content = profile_get_user_profile_html($user, $section); - $content = elgg_view_layout($layout, $content); + $content = elgg_view_layout($layout, array('content' => $content)); break; } diff --git a/mod/reportedcontent/add.php b/mod/reportedcontent/add.php index 833ff38d1..1194627f1 100644 --- a/mod/reportedcontent/add.php +++ b/mod/reportedcontent/add.php @@ -22,8 +22,10 @@ $area2 .= elgg_view_title(elgg_echo('reportedcontent:this'), false); $area2 .= elgg_view('reportedcontent/form'); $area3 .= elgg_echo('reportedcontent:warning'); -// Format page -$body = elgg_view_layout('one_column_with_sidebar', $area2, $area3); +$params = array( + 'content' => $area2, + 'sidebar' => $area3 +); +$body = elgg_view_layout('one_column_with_sidebar', $params); -// Draw it -echo elgg_view_page(elgg_echo('reportedcontent:this'),$body);
\ No newline at end of file +echo elgg_view_page(elgg_echo('reportedcontent:this'), $body);
\ No newline at end of file diff --git a/mod/riverdashboard/index.php b/mod/riverdashboard/index.php index b11dade19..8d650e1f5 100644 --- a/mod/riverdashboard/index.php +++ b/mod/riverdashboard/index.php @@ -58,7 +58,12 @@ elgg_set_context('riverdashboard'); if (empty($callback)) { $body .= elgg_view('riverdashboard/container', array('body' => $nav . $extend . $river . elgg_view('riverdashboard/js'))); - echo elgg_view_page($title_wording,elgg_view_layout('one_column_with_sidebar', $title . $body, $sidebar)); + $params = array( + 'content' => $title . $body, + 'sidebar' => $sidebar + ); + $body = elgg_view_layout('one_column_with_sidebar', $params); + echo elgg_view_page($title_wording, $body); } else { header("Content-type: text/html; charset=UTF-8"); echo $nav . $river . elgg_view('riverdashboard/js'); diff --git a/mod/search/index.php b/mod/search/index.php index 035401640..7f7be9860 100644 --- a/mod/search/index.php +++ b/mod/search/index.php @@ -139,7 +139,7 @@ if (!$query) { $body = elgg_view_title(elgg_echo('search:search_error')); $body .= elgg_view('page_elements/content', array('body' => elgg_echo('search:no_query'))); - $layout = elgg_view_layout('one_column_with_sidebar', $body); + $layout = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); echo elgg_view_page($title, $layout); return; diff --git a/mod/search/views/default/search/layout.php b/mod/search/views/default/search/layout.php index 732415f0e..82f191e8c 100644 --- a/mod/search/views/default/search/layout.php +++ b/mod/search/views/default/search/layout.php @@ -6,4 +6,4 @@ * @subpackage Core */ -echo elgg_view_layout('one_column_with_sidebar', $vars['body']);
\ No newline at end of file +echo elgg_view_layout('one_column_with_sidebar', array('content' => $vars['body']));
\ No newline at end of file diff --git a/mod/sitepages/index.php b/mod/sitepages/index.php index f1f6585da..053f82996 100644 --- a/mod/sitepages/index.php +++ b/mod/sitepages/index.php @@ -36,6 +36,10 @@ $members = elgg_get_entities_from_metadata(array( //include sidebar free text
$sidebar = elgg_view('sitepages/sidebar');
$sidebar .= elgg_view('sitepages/members', array('members' => $members));
-
-$content = elgg_view_layout('frontpage', $content, $sidebar);
+
+$params = array(
+ 'content' => $content,
+ 'sidebar' => $sidebar
+);
+$content = elgg_view_layout('frontpage', $params);
echo elgg_view_page(null, $content);
diff --git a/mod/sitepages/sitepages_functions.php b/mod/sitepages/sitepages_functions.php index 38c793074..f1dfdd047 100644 --- a/mod/sitepages/sitepages_functions.php +++ b/mod/sitepages/sitepages_functions.php @@ -97,7 +97,7 @@ function sitepages_get_page_content($page_type) { $body .= elgg_view('page_elements/content', array('body' => elgg_echo('sitepages:notset'))); } - $content = elgg_view_layout('one_column_with_sidebar', $body); + $content = elgg_view_layout('one_column_with_sidebar', array('content' => $body)); return $content; } diff --git a/mod/tagcloud/tagcloud.php b/mod/tagcloud/tagcloud.php index de384b25b..f5554ccba 100644 --- a/mod/tagcloud/tagcloud.php +++ b/mod/tagcloud/tagcloud.php @@ -9,8 +9,10 @@ require_once(dirname(dirname(dirname(__FILE__))) . "/engine/start.php"); $title = elgg_view_title(elgg_echo('tagcloud:site:title')); $tags = display_tagcloud(0, 100, 'tags'); -//select the correct canvas area -$body = elgg_view_layout("one_column_with_sidebar", $title . $tags, $sidebar); +$params = array( + 'content' => $title . $tags, + 'sidebar' => $sidebar +); +$body = elgg_view_layout("one_column_with_sidebar", $params); -// Display page echo elgg_view_page(elgg_echo('tagcloud:site:title', array($page_owner->name)), $body);
\ No newline at end of file diff --git a/mod/thewire/add.php b/mod/thewire/add.php index 3b71cc1d6..12d3f8d8d 100644 --- a/mod/thewire/add.php +++ b/mod/thewire/add.php @@ -17,7 +17,7 @@ $area2 = elgg_view_title(elgg_echo('thewire:add')); $area2 .= elgg_view("thewire/forms/add"); - $body = elgg_view_layout("one_column_with_sidebar", $area2); + $body = elgg_view_layout("one_column_with_sidebar", array('content' => $area2)); // Display page echo elgg_view_page(elgg_echo('thewire:addpost'),$body); diff --git a/mod/thewire/everyone.php b/mod/thewire/everyone.php index 74293d26f..dc6b47e71 100644 --- a/mod/thewire/everyone.php +++ b/mod/thewire/everyone.php @@ -18,7 +18,7 @@ $offset = (int)get_input('offset', 0); $area2 .= elgg_list_entities(array('types' => 'object', 'subtypes' => 'thewire', 'offset' => $offset)); - $body = elgg_view_layout("one_column_with_sidebar", $area2); + $body = elgg_view_layout("one_column_with_sidebar", array('content' => $area2)); // Display page echo elgg_view_page(elgg_echo('thewire:everyone'),$body); diff --git a/mod/thewire/index.php b/mod/thewire/index.php index a1de242c5..36dc5ddab 100644 --- a/mod/thewire/index.php +++ b/mod/thewire/index.php @@ -30,7 +30,7 @@ $area2 .= list_user_objects($page_owner->getGUID(),'thewire'); //select the correct canvas area - $body = elgg_view_layout("one_column_with_sidebar", $area2); + $body = elgg_view_layout("one_column_with_sidebar", array('content' => $area2)); // Display page echo elgg_view_page(elgg_echo('thewire:user', array($page_owner->name)), $body); |