Oh, I wasn’t running the latest version of PRO. Updating to 5.7.11 fixed my issue.
Whatever bug is causing this for repeaters is probably also causing get_field_objects to not capture sub_fields of field type “group”. I just submitted a ticket about this with screenshots.
Fixed! The issue was I was calling acf_form_head()
in an action inside my functions.php page. Once I delete that call and then placed the call at the top of the .php file loading the page it now works magically (using the actual field key in the form was necessary too.)
This sounds like a very similar issue, however if I use the field key field_57b955b462541
in my acf_form it doesn’t fix the issue.
support.advancedcustomfields.com/forums/topic/problems-manually-updating-a-repeater-field-via-code-on-a-newly-inserted-post/
Hi Elliot,
Thanks for your advice & speedy response. It still wasn’t working, but I figured out what was wrong: In the usage code snippet you have on that page you linked to, you have the add_action as:
add_action('acf_head-input', 'my_head_input');
From your notice bar on that page I gather that’s only for version 3 of ACF, so I updated that action to:
add_action('acf/input/admin_head', 'my_head_input');
and it works like a charm 🙂 Think that usage code might need an update for those chumps (like me) who copy and paste it straight into functions.php
Thanks for your help!! (ACF is so awesome)
K