1 block.page_components.inc | PageComponents::getChildren() |
Allows an array of "child blocks" for display in the "Add Block" dialog.
This allows a single entry in hook_block_info() to provide multiple block instances displaying different fields.
Note that this function may return NULL or an empty array, which have different meanings. NULL means that a block does not provide children at all. An empty array means that a block may provide children, but that there are none currently.
Return value
array|null:
Overrides Block::getChildren
File
- core/
modules/ system/ block.page_components.inc, line 143
Class
- PageComponents
- PageComponents extends Block
Code
function getChildren() {
return array(
'title_combo' => array(
'info' => t('Page title combo'),
'description' => t('Displays the page title, tabs (local tasks), local actions links, and messages. Replaces all the normal equivalents on the page with a single block.'),
),
'tabs' => array(
'info' => t('Page tabs (Local tasks)'),
'description' => t('Displays the links for menu local tasks, such as "View" or "Edit". Replaces the normal tabs on the page with a block.'),
),
'title' => array(
'info' => t('Page title'),
'description' => t('Displays the page title. Replaces the normal page title with a block.'),
),
'action_links' => array(
'info' => t('Page local actions'),
'description' => t('Displays the local actions links, such as "Add content". Replaces the normal local actions on the page with a block.'),
),
'messages' => array(
'info' => t('Page messages'),
'description' => t('Displays messages to the user after an action is performed, such as form validation errors or success messages. Replaces the normal messages on the page with a block.'),
),
);
}