You are here

function panels_page_enable_page in Panels 5.2

Same name and namespace in other branches
  1. 6.2 panels_page/panels_page.admin.inc \panels_page_enable_page()

Enable a default panel.

1 string reference to 'panels_page_enable_page'
panels_page_menu in panels_page/panels_page.module
Implementation of hook_menu().

File

panels_page/panels_page.admin.inc, line 110
panels_page.admin.inc

Code

function panels_page_enable_page($name = NULL) {
  $defaults = panels_page_default_panels();
  if (isset($defaults[$name])) {
    $status = variable_get('panel_page_defaults', array());
    $status[$name] = FALSE;
    variable_set('panel_page_defaults', $status);
    menu_rebuild();
    drupal_set_message(t('Panel page enabled'));
  }
  drupal_goto();
}