_overlay_region_list

function _overlay_region_list

_overlay_region_list($type)

Returns a list of page regions related to the overlay.

Parameters

$type: The type of regions to return. This can either be 'overlay_regions' or 'overlay_supplemental_regions'.

Return value

An array of region names of the given type, within the theme that is being used to display the current page.

See also

overlay_regions()

overlay_supplemental_regions()

File

modules/overlay/overlay.module, line 808
Displays the Drupal administration interface in an overlay.

Code

function _overlay_region_list($type) {
  // Obtain the current theme. We need to first make sure the theme system is
  // initialized, since this function can be called early in the page request.
  drupal_theme_initialize();
  $themes = list_themes();
  $theme = $themes[$GLOBALS['theme']];
  // Return the list of regions stored within the theme's info array, or an
  // empty array if no regions of the appropriate type are defined.
  return !empty($theme->info[$type]) ? $theme->info[$type] : array();
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!overlay!overlay.module/function/_overlay_region_list/7.x

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部