Active
Project:
Giga Menu
Version:
7.x-1.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Feb 2012 at 09:54 UTC
Updated:
3 Feb 2012 at 10:01 UTC
Giga Menu does not generate the block for the menus those have a space in the title, which will be replaced with dash (-) in it's machine name. I put the following code in hook_block_info() to solve this problem:
(around line 72-76 in gigamenu.module)
if (variable_get('gigamenu_enabled_' . $name, FALSE)) {
$name = str_replace('-', '_', $name); // <-- Fix this issue by mangle dash with underscore
$blocks['gigamenu_' . $name]['info'] = t('Giga menu: !name', array('!name' => check_plain($title)));
$blocks['gigamenu_' . $name]['cache'] = DRUPAL_NO_CACHE;
}
Comments
Comment #1
BoogieBug commentedYou will also need to convert it back in hook_block_view() with following code: