- This topic has 3 replies, 2 voices, and was last updated 4 years, 7 months ago by .
-
Topic
-
Hello I am having a problem, I not find anything related.
If I have a subgroup with Group enabled to clone, I can not use the max_cloner. (The button clone the main group disappears)
If I do not have a Subgroup and use max_cloner works perfectly.
add_filter( 'rwmb_meta_boxes', 'demo_nested_groups' ); function demo_nested_groups( $meta_boxes ) { $meta_boxes[] = array( 'title' => __( 'Multi-level nested groups', 'textdomain' ), 'fields' => array( array( 'id' => 'group', 'type' => 'group', 'clone' => true, 'max_clone' => 5, 'fields' => array( // Normal field (cloned) array( 'name' => __( 'Text', 'textdomain' ), 'id' => 'text', 'type' => 'text', 'clone' => true, ), // Nested group level 2 array( 'name' => __( 'Sub group', 'textdomain' ), 'id' => 'sub_group', 'type' => 'group', 'clone' => true, 'fields' => array( // Normal field (cloned) array( 'name' => __( 'Sub text', 'textdomain' ), 'id' => 'sub_text', 'type' => 'text', 'clone' => true, ), ), ), ), ), ), ); return $meta_boxes; }
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- You must be logged in to reply to this topic.