Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I made a patch so we can alter a homebox page using hook_homebox_page_alter(&$page)
. Please correct me if there's something wrong with the patch. I hope this feature (altering already generated homebox page) can be added in the future release.
To use this hook, put in yourmodule.module something like this (in this example I'm adding custom menu to testbox homebox page):
function yourmodule_homebox_page_alter(&$page) {
if ($page->name == 'testbox') {
$page->settings['blocks']['menu_menu-ap'] = array (
'module' => 'menu',
'delta' => 'menu-ap',
'region' => 3,
'movable' => 1,
'status' => 0,
'open' => 1,
'closable' => 1,
'title' => '',
'weight' => -33,
);
}
}
Comment | File | Size | Author |
---|---|---|---|
homebox.module.patch | 943 bytes | agungsuyono | |
Comments
Comment #1
drummDrupal 6 is no longer supported. If this can be reproduced with Drupal 7, please re-open with details.