From 562bc001f3002f43c343cc63bbbe3e9cb421de32 Mon Sep 17 00:00:00 2001 From: ewinslow Date: Fri, 18 Feb 2011 18:03:24 +0000 Subject: Refs #2950: layout/shells => page/layouts git-svn-id: http://code.elgg.org/elgg/trunk@8286 36083f99-b078-4883-b0ff-0f9b5a30f544 --- views/default/page/layouts/widgets.php | 53 ++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 views/default/page/layouts/widgets.php (limited to 'views/default/page/layouts/widgets.php') diff --git a/views/default/page/layouts/widgets.php b/views/default/page/layouts/widgets.php new file mode 100644 index 000000000..8d122738e --- /dev/null +++ b/views/default/page/layouts/widgets.php @@ -0,0 +1,53 @@ +guid, $context); + +if (elgg_can_edit_widget_layout($context)) { + if ($show_add_widgets) { + echo elgg_view('layout/shells/widgets/add_button'); + } + $params = array( + 'widgets' => $widgets, + 'context' => $context, + 'exact_match' => $exact_match, + ); + echo elgg_view('layout/shells/widgets/add_panel', $params); +} + +echo $vars['content']; + +$widget_class = "elgg-col-1of{$num_columns}"; +for ($column_index = 1; $column_index <= $num_columns; $column_index++) { + $column_widgets = $widgets[$column_index]; + + echo "
"; + if (is_array($column_widgets) && sizeof($column_widgets) > 0) { + foreach ($column_widgets as $widget) { + echo elgg_view_entity($widget, array('show_access' => $show_access)); + } + } + echo '
'; +} + +elgg_pop_context(); + +echo elgg_view('graphics/ajax_loader', array('id' => 'elgg-widget-loader')); -- cgit v1.2.3