function panelizer_requirements in Panelizer 7
Same name and namespace in other branches
- 8.5 panelizer.install \panelizer_requirements()
- 6 panelizer.install \panelizer_requirements()
- 7.3 panelizer.install \panelizer_requirements()
- 7.2 panelizer.install \panelizer_requirements()
Implements hook_requirements().
File
- ./
panelizer.install, line 10 - Install, update and uninstall functions for the panelizer module.
Code
function panelizer_requirements($phase) {
$requirements = array();
if ($phase == 'runtime') {
$node_view = page_manager_get_task('node_view');
if ($node_view['disabled']) {
$requirements['panelizer'] = array(
'title' => t('Panelizer'),
'value' => t('You must enable the %node_view page template in <a href="@url">page manager</a> to use panelizer.', array(
'%node_view' => 'node_view',
'@url' => url('admin/structure/pages'),
)),
'severity' => REQUIREMENT_ERROR,
);
}
}
return $requirements;
}