Metaboxes not saving upon deactivating MetaBox Builder
Support › Meta Box AIO › Metaboxes not saving upon deactivating MetaBox BuilderResolved
- This topic has 2 replies, 2 voices, and was last updated 4 years, 10 months ago by
Newbreak Media.
Viewing 3 posts - 1 through 3 (of 3 total)
-
AuthorPosts
-
June 4, 2020 at 6:17 AM #20205
Newbreak Media
Participanthi. as long as I have MetaBox and MetaBox AIO installed, the meta boxes show up fine.
When I deactivate just MetaBox AIO, the meta boxes go away and the groups collapse to just one line...can you please help?
here is my code:
function nbm_events_create_main_mb( $meta_boxes ) { $prefix = 'event-'; $meta_boxes[] = array ( 'title' => esc_html__( 'Events Metabox', 'nbm-events' ), 'id' => 'nbm_events_main', 'post_types' => array( 0 => 'events', ), 'context' => 'normal', 'priority' => 'high', 'fields' => array( array ( 'id' => $prefix . 'whenwhere', 'type' => 'group', 'name' => esc_html__( 'WHEN & WHERE', 'nbm-events' ), 'fields' => array( array ( 'id' => $prefix . 'start', 'type' => 'datetime', 'name' => esc_html__( 'Event Starts', 'nbm-events' ), ), array ( 'id' => $prefix . 'end', 'type' => 'datetime', 'name' => esc_html__( 'Event Ends', 'nbm-events' ), ), array ( 'id' => $prefix . 'loc-opt', 'name' => esc_html__( 'Radio', 'nbm-events' ), 'type' => 'radio', 'options' => array( 'online' => esc_html__( 'Online', 'nbm-events' ), 'efcc' => esc_html__( 'EFCC', 'nbm-events' ), 'off' => esc_html__( 'Off-Campus', 'nbm-events' ), ), 'required' => 1, ), array ( 'id' => $prefix . 'loc-name', 'type' => 'text', 'name' => esc_html__( 'Location Name', 'nbm-events' ), 'visible' => array( 'when' => array( array ( 0 => 'loc-opt', 1 => '=', 2 => 'off', ), ), 'relation' => 'and', ), ), array ( 'id' => $prefix . 'loc-address', 'type' => 'text', 'name' => esc_html__( 'Address', 'nbm-events' ), 'visible' => array( 'when' => array( array ( 0 => 'loc-opt', 1 => '=', 2 => 'off', ), ), 'relation' => 'and', ), ), array ( 'id' => $prefix . 'loc-bld', 'type' => 'text', 'name' => esc_html__( 'Building / Room #', 'nbm-events' ), 'visible' => array( 'when' => array( array ( 0 => 'loc-opt', 1 => '=', 2 => 'efcc', ), ), 'relation' => 'and', ), ), ), 'default_state' => 'expanded', 'columns' => 4, ), array ( 'id' => $prefix . 'registration', 'type' => 'group', 'name' => esc_html__( 'REGISTRATION', 'nbm-events' ), 'fields' => array( array ( 'id' => $prefix . 'reg-req', 'name' => esc_html__( 'Registration Required?', 'nbm-events' ), 'type' => 'checkbox', ), array ( 'id' => $prefix . 'reg-link', 'type' => 'url', 'name' => esc_html__( 'Registration Link', 'nbm-events' ), 'visible' => array( 'when' => array( array ( 0 => 'reg-req', 1 => '=', 2 => 1, ), ), 'relation' => 'and', ), ), array ( 'id' => $prefix . 'cost-req', 'name' => esc_html__( 'Is there a Cost?', 'nbm-events' ), 'type' => 'checkbox', ), array ( 'id' => $prefix . 'cost', 'type' => 'text', 'name' => esc_html__( 'Cost', 'nbm-events' ), 'visible' => array( 'when' => array( array ( 0 => 'cost-req', 1 => '=', 2 => 1, ), ), 'relation' => 'and', ), ), ), 'default_state' => 'expanded', 'columns' => 4, ), array ( 'id' => $prefix . 'poc', 'type' => 'group', 'name' => esc_html__( 'POINT OF CONTACT', 'nbm-events' ), 'fields' => array( array ( 'id' => $prefix . 'poc-name', 'type' => 'text', 'name' => esc_html__( 'Contact Name', 'nbm-events' ), ), array ( 'id' => $prefix . 'poc-email', 'name' => esc_html__( 'Contact Email', 'nbm-events' ), 'type' => 'email', ), array ( 'id' => $prefix . 'poc-tel', 'type' => 'text', 'name' => esc_html__( 'Contact Number', 'nbm-events' ), ), ), 'default_state' => 'expanded', 'columns' => 4, ), ), 'text_domain' => 'nbm-events', ); return $meta_boxes; }
June 4, 2020 at 9:46 AM #20211Long Nguyen
ModeratorHi Emily,
If you deactivate the plugin Meta Box AIO, please activate plugins support the feature that you are using in the code
- fieldgroup
: activate MB Group plugin.
- conditional logicvisible
: activate MB Conditional Logic plugin.June 5, 2020 at 4:33 AM #20218Newbreak Media
Participantgot it. thank you 🙂
-
AuthorPosts
Viewing 3 posts - 1 through 3 (of 3 total)
- You must be logged in to reply to this topic.