if ($needLayout) { ?> <div class="cleantheme-content-layout"> <div class="cleantheme-content-layout-row"> <?php } foreach ($places as $widgets) { if ($needLayout) { ?> <div class="cleantheme-layout-cell cleantheme-layout-cell-size<?php echo $place_count; ?> "> <?php } foreach ($widgets as $widget) { theme_print_widget($widget); } if ($needLayout) { ?> </div> <?php } } if ($needLayout) { ?> </div> </div> <?php } }
function theme_print_sidebar($sidebar_id, $before = '', $after = '') { $widgets = theme_get_dynamic_sidebar_data($sidebar_id); if (!is_array($widgets) || count($widgets) < 1) { return false; } echo $before; foreach ($widgets as $widget) { theme_print_widget($widget); } echo $after; return true; }