Support Forum
Support › Meta Box AIO › 12 Columns not working
Hello.
When we create a new custom field, select 12 column as size, it looks like in this image: https://imgur.com/a/sJLExYU and not text above, editor below.
If we select 11 column, it works fine.
I noticed, if using 12 column, the CSS is different, in 11 column or below the html/css looks like this:
<div class="rwmb-column rwmb-column-11 "><div class="rwmb-field rwmb-wysiwyg-wrapper">
If i change this to 12, it works fine. "column-11".
If i change to 12 columns in the builder, it doesn't load that html at all.
Please let me know how to fix it.
Thanks
I noticed also now, if i generate the PHP for it, it looks like this:
11 COLUMNS:
<?php
add_filter( 'rwmb_meta_boxes', 'your_prefix_function_name' );
function your_prefix_function_name( $meta_boxes ) {
$prefix = '';
$meta_boxes[] = [
'title' => __( 'Driftdokument - Systeminfo', 'your-text-domain' ),
'id' => 'driftdokument-systeminfo',
'post_types' => ['drift-dokument'],
'closed' => true,
'default_hidden' => false,
'autosave' => true,
'revision' => true,
'storage_type' => 'custom_table',
'table' => 'wpinsidan_drift_dokument',
'fields' => [
[
'name' => __( 'Wysiwyg', 'your-text-domain' ),
'id' => $prefix . 'wysiwyg_u9wdm8qq34e',
'type' => 'wysiwyg',
'raw' => false,
'required' => false,
'clone' => false,
'clone_empty_start' => false,
'columns' => 11,
'hide_from_rest' => false,
'hide_from_front' => false,
'limit_type' => 'character',
],
],
];
return $meta_boxes;
}
12 COLUMNS:
<?php
add_filter( 'rwmb_meta_boxes', 'your_prefix_function_name' );
function your_prefix_function_name( $meta_boxes ) {
$prefix = '';
$meta_boxes[] = [
'title' => __( 'Driftdokument - Systeminfo', 'your-text-domain' ),
'id' => 'driftdokument-systeminfo',
'post_types' => ['drift-dokument'],
'closed' => true,
'default_hidden' => false,
'autosave' => true,
'revision' => true,
'storage_type' => 'custom_table',
'table' => 'wpinsidan_drift_dokument',
'fields' => [
[
'name' => __( 'Wysiwyg', 'your-text-domain' ),
'id' => $prefix . 'wysiwyg_u9wdm8qq34e',
'type' => 'wysiwyg',
'raw' => false,
'required' => false,
'clone' => false,
'clone_empty_start' => false,
'hide_from_rest' => false,
'hide_from_front' => false,
'limit_type' => 'character',
],
],
];
return $meta_boxes;
}
So on 12 columns, it doesn't generate columns => 12.
Hello Oskar,
The default number of columns is 12. So the setting won't be generated to the PHP code. Actually, it only works if you change the number of columns to a different from 12 then you can see an additional HTML + column class. I see that it works properly and is not an issue with the columns.
Hello,
Well, even if we select no columns data, it looks like in the images. It doesn't go 100%.
It just looks completely broken.
How can we solve this?
Peter, see the video here: https://imgur.com/a/xV9Cab9
What can cause this?
Here is more data for debug.
I have 2 custom fields created, one works, one don't.
Both have 12 columns selected (i tried empty as well) and the source code looks like this: https://imgur.com/a/1ZekzUD
They are different.
Let me know what you think.
Hello,
I can see and reproduce the issue. Do you register a custom field with code and add the columns
setting manually? It is a small issue with the field appearance so I will ask the development team to check and fix this in the next update of the plugin.
You can use the builder to register all fields to have one kind of format.
Hello!
I use only the builder for all fields.
Can i do some workaround for it to work until there is a fix?
Thanks
Please share your site admin account by submitting this contact form https://metabox.io/contact/
I will take a look.