diff --git a/stanford_soe_regions.module b/stanford_soe_regions.module index 3f39864..7ed7644 100644 --- a/stanford_soe_regions.module +++ b/stanford_soe_regions.module @@ -11,10 +11,28 @@ function stanford_soe_regions_define_regions() { $region['full_width_super_hero'] = array( 'title' => 'Full Width Super Hero', - 'js' => drupal_get_path('module', 'stanford_soe_regions') . '/js/stanford_soe_regions.js', - 'css' => drupal_get_path('module', 'stanford_soe_regions') . '/css/stanford_soe_regions.css', + //'js' => drupal_get_path('module', 'stanford_soe_regions') . '/js/stanford_soe_regions.js', + //'css' => drupal_get_path('module', 'stanford_soe_regions') . '/css/stanford_soe_regions.css', 'render_callback' => '_full_width_super_hero_render_region', ); + $region['content_body_lower'] = array( + 'title' => 'Content Body Lower', + //'js' => drupal_get_path('module', 'stanford_soe_regions') . '/js/stanford_soe_regions.js', + //'css' => drupal_get_path('module', 'stanford_soe_regions') . '/css/stanford_soe_regions.css', + 'render_callback' => '_content_body_lower_render_region', + ); + $region['full_width_middle'] = array( + 'title' => 'Full Width Middle', + //'js' => drupal_get_path('module', 'stanford_soe_regions') . '/js/stanford_soe_regions.js', + //'css' => drupal_get_path('module', 'stanford_soe_regions') . '/css/stanford_soe_regions.css', + 'render_callback' => '_full_width_middle_render_region', + ); + $region['content_body_bottom'] = array( + 'title' => 'Content Body Lower', + //'js' => drupal_get_path('module', 'stanford_soe_regions') . '/js/stanford_soe_regions.js', + //'css' => drupal_get_path('module', 'stanford_soe_regions') . '/css/stanford_soe_regions.css', + 'render_callback' => '_content_body_bottom_render_region', + ); return $region; } @@ -27,6 +45,33 @@ function _full_width_super_hero_render_region($block_html, $block) { return $output; } +/** + * Helper function for rendering the blocks in this region + */ +function _content_body_lower_render_region($block_html, $block) { + $renderable_block = _block_get_renderable_array(array($block)); + $output = drupal_render($renderable_block); + return $output; +} + +/** + * Helper function for rendering the blocks in this region + */ +function _full_width_middle_render_region($block_html, $block) { + $renderable_block = _block_get_renderable_array(array($block)); + $output = drupal_render($renderable_block); + return $output; +} + +/** + * Helper function for rendering the blocks in this region + */ +function _content_body_bottom_render_region($block_html, $block) { + $renderable_block = _block_get_renderable_array(array($block)); + $output = drupal_render($renderable_block); + return $output; +} + /** * Implements hook_page_alter(). */ diff --git a/templates/digital-magazine-page.tpl.php b/templates/digital-magazine-page.tpl.php index 3bb0290..9658a97 100644 --- a/templates/digital-magazine-page.tpl.php +++ b/templates/digital-magazine-page.tpl.php @@ -263,6 +263,24 @@ + +