You are here

function template_preprocess_rotor_view_rotor in Rotor Banner 7

Same name and namespace in other branches
  1. 6.2 theme/theme.inc \template_preprocess_rotor_view_rotor()

Preprocess the primary theme implementation for a view.

File

theme/theme.inc, line 11
theme.inc Preprocessing for views themes.

Code

function template_preprocess_rotor_view_rotor(&$vars) {
  $view = $vars['view'];
  $vars['css_name'] = views_css_safe($view->name);
  $vars['name'] = $view->name;
  $vars['display_id'] = $view->current_display;
  $vars['style'] = '';
  if ($vars['options']['width'] > 0) {
    $vars['style'] .= ' width: ' . $vars['options']['width'] . 'px;';
  }
  if ($vars['options']['height'] > 0) {
    $vars['style'] .= ' height: ' . $vars['options']['height'] . 'px;';
  }
}