Support Forum
Support › MB Settings Page › Settings Page StyleResolved
Hi there!
I recently decided to update the Settings Page extension and it appears that it breaks the style? The "style" => "no-boxes" option seems to be completely ignored and I keep seeing the boxed layout.
Once I load the old settings page version, everything works like a charm again?
Regards,
Filip
Hi Filip,
I've just tested and it works well. Can you share your code?
I think I have the same problem, I think I found out why. To me this looks like a bug.
When you have just style=no-boxes
and columns=1
set, nothing changed and you still get the boxed layout.
When you add the tabs
key, then the no-boxes
layout kicks in.
$settings_pages[] = [
'id' => 'vacancies',
'option_name' => 'vacancy',
'menu_title' => __('Vacancies', 'vac'),
'parent' => 'options-general.php',
'style' => 'no-boxes',
'columns' => 1,
// remove this and the box layout appears
'tabs' => [ 'test' => "Test" ]
];
This is undesirable because we just want to mimic a normal WP settings page, those don't have tabs and no white boxes.
Or am I missing something?
Hi,
Thank you. I'm going to check it out and let you know later.
Hi Long, I am seeing the same thing. no-boxes style is being ignored if tabs are not present. I think myself and the other commentators want a single page, flat settings page. no tabs, no boxes, just basic fields. Thanks
public function settings_page( array $settings_pages ) : array {
$settings_pages[] = array(
'id' => 'social-media',
'option_name' => 'poa',
'menu_title' => esc_html__( 'Social Media', 'poa' ),
'parent' => 'options-general.php',
'style' => 'no-boxes',
'columns' => 1,
);
return $settings_pages;
}
Hi guys,
Please update the latest version of MB AIO to v1.11.9 or MB Settings Page to v2.1.1 to fix this issue.
Hi Long,
This fixes the issue. Great work, thanks a lot!
Hi Long, thanks for pushing a patch. I am using Composer to load this plugin with this code
"meta-box/mb-settings-page": "dev-master"
But after running this command, Composer says there is nothing to update.
composer update meta-box/mb-settings-page
Do you all need to push the code to the master branch or tag the release?
@content Pilot
You need to clear the composer cache and re-install (not update) the vendor plugins.
rm -rf vendor && composer clear-cache && composer install
See the docs here: https://docs.metabox.io/extensions/composer/#versions--updates
@Comsi. bless you. it's always the cache, isn't it?
Ain't that the truth. 😉
Hey there!
Is that possible to have the "style" => "seamless" on a specific BOX inside a tabbed settings panel?
If I set SEAMLESS in the box anywhere inside a page, or CPT, it works fine. But inside the setting page, does not.
$meta_boxes[] = array(
'id' => 'my-id',
'title' => 'my-title',
'settings_pages' => 'panel-abc',
'tab' => 'tab-123,
'style' => 'seamless',
'fields' => array(
array(
'name' => 'Setting name',
'id' => 'sett-id',
'type' => 'text',
'class' => 'my-class',
'columns' => 6
),
array(
'name' => 'Other setting name',
'id' => 'sett-id-2',
'type' => 'text',
'class' => 'my-class',
'columns' => 6
)
)
);
Thank you!!!
G.
Hi,
Thanks for your idea, I'm going to create a feature request to support style seamless (no-box) in the setting page for specific meta boxes.
Solved in MB Settings Page v2.1.3, MB AIO will be released later.
'style' => 'boxes'
'style' => 'seamless'
THANK YOU!
SO MUCH.