I would like the change the menu setting on the header block when a user enables the Tatsu theme.
Is there any way to do that?
Here is the code I would use in hook_install for a module, is there a version of this for a theme:
$layouts = layout_get_all_configs('layout');
foreach ($layouts as $layout_name => $layout) {
foreach ($layout['content'] as $block_id => $block) {
if ($block['plugin'] === 'system:header') {
config_set('layout.layout.' . $layout_name, 'content.' . $block_id . '.data.settings.block_settings.menu', 'my-menu-id');
}
}
}
Recent comments
Heya @DrAlbany, Yes, if you could add me as a contributor that would be great. I'm doing a bunch of "triage" on my site these days, fixing stuff and (slowly)...
Ubercart Product Kit(s) - Advice, Tips, Lore, Acumen
Wow! @bugfolder What a fantastic response! I am so grateful for the effort you obviously put in. I just wanted to give you some FF on the sheer size and depth of...
Ubercart Product Kit(s) - Advice, Tips, Lore, Acumen
Hi..., Our ubercart.dev site is a work in progress... I'm happy to add you as a contributor etc... UC is something I use and want to help the documentation live on...
Ubercart Product Kit(s) - Advice, Tips, Lore, Acumen
Hi Graham, I don't have answers to all your questions, but I do for some: answers inline below. Thank you for your comments, especially the assurance(s) that UC Product Kit...
Ubercart Product Kit(s) - Advice, Tips, Lore, Acumen
hello @yorkshirepudding It's nice to be in contact again! Wonderful information! Thanks! Will definitely check it out! g ----
Ubercart Product Kit(s) - Advice, Tips, Lore, Acumen