You are here

function ultimenu_remove_ultimenu_theme_info in Ultimenu 7

Colllects unwanted Ultimenu regions for removal stored in the theme .info.

When a menu item disabled or deleted, relevant dynamic Ultimenu regions removed from the system, but theme .info has a copy stored there. System will always keep and display the unwanted. Either manually delete it from .info, or do a force removal if so configured.

Return value

array|bool The array of unwanted Ultimenu regions from theme .info, or FALSE.

2 calls to ultimenu_remove_ultimenu_theme_info()
ultimenu_admin_settings in includes/ultimenu.admin.inc
Menu callback for 'admin/structure/ultimenu'.
ultimenu_system_info_alter in ./ultimenu.module
Implements hook_system_info_alter().

File

includes/ultimenu.utilities.inc, line 187
Misc functions that hardly change.

Code

function ultimenu_remove_ultimenu_theme_info() {
  $goodies = ultimenu_get_settings('goodies');
  if (!empty($goodies['force-remove-region']) && ($theme_regions = ultimenu_get_ultimenu_theme_info())) {
    return $theme_regions;
  }
  return FALSE;
}