Home › Forums › Add-ons › Repeater Field › Add Row to Nested Repeater Field › Reply To: Add Row to Nested Repeater Field
Hi @jtnatoli
Currently, the update_function will override the current value completely, which makes adding a row a bit of a hastle.
You will have to use the get_field function to load the entire repeater (parent repeater) and then add your new row to the nested repeater.
So, using the name of the list, you could get the parent repeater, loop through the rows and when you match the list name to that row’s list name value, you can then add to the corresponding causes.
Then, use the update_value function on the updated value.
Good luck!
Cheers
E
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.