Support

Account

Home Forums Front-end Issues How to show ACF Repeater in front end form Reply To: How to show ACF Repeater in front end form

  • Hi @madhan2085

    I believe you don’t need to use this code if you don’t use AJAX to load the form:

    <script type="text/javascript">
        (function($) {
            // setup fields
        acf.do_action('append', $('#popup-id'));
        })(jQuery);	
    </script>

    Regarding your issue, it seems there’s something wrong with this code:

    ‘field_groups’ => array('field_57aad46f04ccc'),

    A field group’s key is formatted like this: group_1234567890abc. If you want to restrict the fields, please use the following code instead:

    ‘fields’ => array('field_57aad46f04ccc'),

    If you want to do it for a field group, you can use the field group ID like this:

    ‘field_groups’ => array(99),

    You can get the ID in the field group editor page’s URL. For example in this link:

    http://example.com/wp-admin/post.php?post=99&action=edit

    ’99’ is the field group ID.

    I hope this makes sense 🙂