Home › Forums › Add-ons › Repeater Field › Can you update a row in a repeater? › Reply To: Can you update a row in a repeater?
I’m having the same issue…sorta. I have the following field defined:
Through code, I am filling out the values of the repeater like so:
$emergency_contact = array('emergency_contact_full_name' => $EMERGENCY_CONTACT_FULL_NAME,
'emergency_contact_relationship_to_you' => $EMERGENCY_CONTACT_RELATIONSHIP,
'emergency_contact_phone' => $EMERGENCY_CONTACT_CONTACT_PHONE
);
update_field('volunteer_emergency_contact', $emergency_contact, $theId);
No errors when that code runs.
But when I try to load the CPT entry, WordPress just hangs and nothing happens. If I remove that line where the code gets updated, everything works just fine.
Am I supposed to create something to update the row in the repeater beforehand? Am a bit confused.
Thanks in advance!
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.