Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- <?php
- add_filter( 'rwmb_meta_boxes', 'your_prefix_register_meta_boxes' );
- function your_prefix_register_meta_boxes( $meta_boxes ) {
- $meta_boxes[] = array (
- 'title' => 'Settings_temp',
- 'id' => 'settings-temp',
- 'post_types' => array (
- 'page',
- ),
- 'context' => 'normal',
- 'priority' => 'high',
- 'status' => 'publish',
- 'autosave' => false,
- 'fields' => array (
- array (
- 'id' => 'group_2',
- 'type' => 'group',
- 'name' => 'Group',
- 'fields' => array (
- array (
- 'id' => 'checkbox_1',
- 'name' => 'Checkbox',
- 'type' => 'checkbox',
- 'desc' => 'Default Description',
- ),
- array (
- 'id' => 'group_3',
- 'type' => 'group',
- 'name' => 'Group',
- 'fields' => array (
- array (
- 'id' => 'checkbox_2',
- 'type' => 'checkbox',
- 'desc' => 'This is some long title',
- 'columns' => 3,
- ),
- array (
- 'id' => 'checkbox_3',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_4',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_5',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_6',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_6',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_7',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_8',
- 'type' => 'checkbox',
- 'columns' => 1,
- ),
- array (
- 'id' => 'checkbox_9',
- 'type' => 'checkbox',
- 'columns' => 2,
- ),
- ),
- 'default_state' => 'expanded',
- 'groupfield' => 'text',
- ),
- ),
- 'default_state' => 'expanded',
- 'groupfield' => 'text',
- 'tab' => 'tab_1',
- ),
- array (
- 'id' => 'text_3',
- 'type' => 'text',
- 'name' => 'Text Field',
- 'std' => 'Logged Out Users',
- 'required' => 1,
- 'tab' => 'tab_1',
- ),
- ),
- 'tab_style' => 'default',
- 'tab_wrapper' => true,
- 'tabs' => array (
- 'tab_1' => array (
- 'label' => 'Tab',
- 'icon' => '',
- ),
- ),
- );
- return $meta_boxes;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement