Custom Fields
Re-Envisioned
Support Meta Box Group Cloned group copies previous 'image_advanced'

This topic contains 11 replies, has 4 voices, and was last updated by  KIM TAE YOUNG 1 month, 4 weeks ago.

  • Creator
    Topic
  • #14991
    Resolved
    Pascal
    Participant

    I saw a similar problem in a previous topic, but it wasn’t quite the same.

    When I create an ‘image_advanced’ field within a group, then save it, then add a new group, the ‘image_advanced’ field gets copied over. The images can be deleted and saved without problems. But they only appear again on a newly added group.

    $meta_boxes[] = array(
      'id' => 'example_metabox',
      'title' => 'Example',
      'post_types' => array('page'),
      'context' => 'advanced',
      'priority' => 'high',
      'autosave' => 'false',
      'fields' => array(
        
        array(
          'id' => '_images_example',
          'type' => 'group',
          'default_state' => 'expanded',
          'collapsible' => true,
          'save_state' => true,
          'clone' => true,
          'sort_clone' => true,
    
          'fields' => array(
            array(
              'id' => '_images',
              'type' => 'image_advanced',
              'name' => 'Images',
            ),
          ),
    
        ),
    
      ),
    );

Viewing 11 replies (of 11 total)
  • Author
    Replies
  • #15128

    KIM TAE YOUNG
    Participant

    It works very well.
    Quick fix Thank you very much!

Viewing 11 replies (of 11 total)

You must be logged in to reply to this topic.