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.
Hi,
I have added a new region, called 'messages', by editing 'openhand.info.yml' and 'flex-builder.markup.yml'.
It appears in the layout section of the settings.
But the theme settings will not now save.
I make any change - hit 'save layout settings', nothing changes.
No error messages.
'openhand.info.yml' edit;
regions:
leaderboard: Leaderboard
header_first: 'Header first'
header_second: 'Header second'
navbar: Navbar
highlighted: Highlighted
messages: Messages
features_first: 'Features first'
features_second: 'Features second'
etc etc
'flex-builder.markup.yml' edit;
rows:
leaderboard: # row key (name of the row).
attributes: # attributes - set id, role, classes.
id: leaderboard
regions:
leaderboard: # region machine name.
label: 'Leaderboard' # region label.
order: 1 # source order in this row.
header:
attributes:
role: banner
id: masthead
regions:
header_first:
label: 'Header first'
order: 1
header_second:
label: 'Header second'
order: 2
navbar:
attributes:
id: navbar
regions:
navbar:
label: 'Navbar'
order: 1
highlighted:
attributes:
id: highlighted
regions:
highlighted:
label: 'Highlighted'
order: 1
messages:
attributes:
id: messages
regions:
messages:
label: 'messages'
order: 1
features:
attributes:
id: features
etc etc
Am I missing something?
Please advise.
Many thanks.
Comments
Comment #2
looklively CreditAttribution: looklively commentedIt seems to be the 'flex-builder.markup.yml' file.
I have replaced it with the original, leaving the edited 'openhand.info.yml' in place, and all works fine.
But as soon as I add an edited version, I cannot save the theme settings.
Any advice very welcomed.
Thanks.
Comment #3
looklively CreditAttribution: looklively commentedI created another sub theme using the generator.
It is saving fine now with the additional region.
So I guess I did something to mess up the othersubtheme.
All good now tho.
Thanks for looking.
Comment #4
looklively CreditAttribution: looklively commentedHi,
So this is still causing me problems.
I see now that I only need to edit 'flex-builder.markup.yml' ... correct ... ?
I have successfully added new regions but have not yet been able to add as many as I need.
The theme settings save, then I add another region and they do not.
Please see the below 2x 'flex-builder.markup.yml'.
The first works - all good, settings save.
The second, with one additinal region, apears in 'layout settings' but the settings will not save .
I am clearing the cache each time.
Is there some limit on the number of regions I can add or something?
Am I doing something wrong or missing something?
This works;
This - one additional region at the bottom - does not;
Comment #5
jwkovell CreditAttribution: jwkovell commentedWe had a similar issue where our theme's settings form would become bogged down with too many fields to save properly. Maybe our solution will work in your case as well.
Depending on how many regions, content types or view modes you have, some of Adaptive Theme's extensions will exponentially increase the number of fields in the settings form. The Image alignment and captions extension was particularly bad at generating hundreds of form fields.
The solution that ended up working for us was:
We we able to make due without the "Image alignment and captions" extension, which I believe was enabled by default. You my also have some extensions you don't need that are enabled by default.
Comment #6
looklively CreditAttribution: looklively commented@jkovell,
Halleluijah.
Yes, thanks your solution woked.
I disabled the Image alignment and captions extension, and a few others.
I am now able to add multiple additional regions.
AT is a very good theme indeed, but I guess this kind of thing is the drawback of the kind of settings/interface complexity it facilitates.
Thanks very much for taking the time to help me.
If you pm me a bitcoin or ether address, I'll send you the price of a coffee.
:)
Comment #7
jwkovell CreditAttribution: jwkovell commentedGlad to help! I'm just glad that your issue reminded me that I should have posted this concern when it first bit me months ago.
Yes, that page IS really complex! Perhaps this should turn into a feature request: "split extension fieldsets out into separate form pages to avoid JavaScript timeout issues" or something like that...
I'll leave that to Jeff to decide if this is more an exception than the norm. For now, the work-around has been sufficient for my own needs.
Comment #8
looklively CreditAttribution: looklively commented+1, buddy.
Gets my vote.
Thanks again for your help.
I was losing hair there ... ;)
Comment #9
Jeff Burnz CreditAttribution: Jeff Burnz commentedIt's a possible case to move it to AT Tools Module, or in fact ALL the extension type settings as sub-modules, something to consider.
Comment #10
Jeff Burnz CreditAttribution: Jeff Burnz commentedI think I will kill enabling Image settings by default, I really want people to use Display Suit anyway as it's far more powerful for laying out stuff.
I'll mark this as fixed for now.
Comment #11
jwkovell CreditAttribution: jwkovell commentedSounds good! If the problem did bite someone now, they'd be more likely to associate it with a setting that they enabled, rather than an unknown default. Thanks!
Comment #12
looklively CreditAttribution: looklively commentedHey Jeff,
Yup +1
Sterling work!
Many thanks that man.
Comment #14
SohelPathan CreditAttribution: SohelPathan as a volunteer commentedYeah....
@jwkovell
Your solution worked for me. Many thanks.
@Jeff,
Have you tacked this issue as suggested by @jwkovell? Because I have faced this issue recently and solved with the solution provided by @jwkovell. I am using AT theme with version 8.x-1.0 and with at_core : 8.x-3.1