You are here

function nd_emptyregionrender_process in Node displays 6

Implementation of nd_pluginname_process().

File

plugins/emptyregionrender.inc, line 50
Plugin to render an empty region.

Code

function nd_emptyregionrender_process(&$vars, &$node_display, $nd_display_settings) {
  foreach ($node_display->all_regions as $region_name => $region_title) {
    $render = nd_default_value($nd_display_settings, $vars['node']->build_mode, 'emptyregionrender', 'render', $region_name, FALSE);
    if ($render == TRUE && !isset($node_display->themed_regions[$region_name])) {
      $node_display->themed_regions[$region_name] = array(
        'content' => ' ',
      );
      if ($region_name == 'left' || $region_name == 'right') {
        $node_display->region_classes[$region_name] = $region_name;
      }
    }
  }
}