1 system.theme.inc theme_admin_page($variables)

Returns HTML for an administrative page.

Parameters

$variables: An associative array containing:

  • blocks: An array of blocks to display. Each array should include a 'title', a 'description' and a formatted 'content'.

Related topics

File

core/modules/system/system.theme.inc, line 432
Theme functions for the System module.

Code

function theme_admin_page($variables) {
  $blocks = $variables['blocks'];
  $container = array();

  foreach ($blocks as $block) {
    if ($block_output = theme('admin_block', array('block' => $block))) {
      $container[] = $block_output;
    }
  }

  if (!empty($container)) {
    $output = '<div class="admin clearfix">';
    foreach ($container as $data) {
      $output .= $data;
    }
    $output .= '</div>';
  }
  else {
    $output = t('You do not have any administrative items.');
  }
  return $output;
}