Permalink
Browse files

Added the missing switch construct to the mymoodle page for flexible …

…column positioning.
  • Loading branch information...
1 parent cfbd464 commit 725685f9fb4ac44ab69af0b4e2908065eadccd7a urs_hunkler committed Sep 20, 2007
Showing with 15 additions and 1 deletion.
  1. +15 −1 mod/chat/view.php
View
@@ -68,11 +68,19 @@
echo '<table id="layout-table"><tr>';
+ $lt = (empty($THEME->layouttable)) ? array('left', 'middle', 'right') : $THEME->layouttable;
+ foreach ($lt as $column) {
+ switch ($column) {
+ case 'left':
+
if(!empty($CFG->showblocksonmodpages) && (blocks_have_content($pageblocks, BLOCK_POS_LEFT) || $PAGE->user_is_editing())) {
echo '<td style="width: '.$blocks_preferred_width.'px;" id="left-column">';
blocks_print_group($PAGE, $pageblocks, BLOCK_POS_LEFT);
echo '</td>';
}
+
+ break;
+ case 'middle':
echo '<td id="middle-column">';
@@ -179,7 +187,13 @@
/// Finish the page
- echo '</td></tr></table>';
+ echo '</td>';
+
+ break;
+ }
+ }
+
+ echo '</tr></table>';
print_footer($course);

0 comments on commit 725685f

Please sign in to comment.