Home › Forums › Add-ons › Repeater Field › Moving meta field data with update_field or add_row › Reply To: Moving meta field data with update_field or add_row
Do not do your second code.
Explanation of db columns
sponsors-v2 = 2, number or rows in the repeater
sponsors-v2_0_organization = 310, row 1 (index 0) organization sub field value
sponsors-v2_0_linked = 0, row 1 (index 0) linked sub field value
sponsors-v2_1_organization = 86, row 2 (index 1) organization sub field value
sponsors-v2_1_linked = 0, row 2 (index 1) linked sub field value
all of these entries are managed automatically by ACF
You should be using add_row()
trying to insert values the way you are will break the repeater.
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’re hard at work on ACF 6.1, and Beta 1 is now available 🚀
— Advanced Custom Fields (@wp_acf) March 16, 2023
This release includes custom post type and taxonomy registration, an improved experience when selecting field types, PHP 8.1 and 8.2 compatibility, and more!
Let’s take a look 🧵https://t.co/Y0WcAT11l4
© 2023 Advanced Custom Fields.
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 Cookie Policy. If you continue to use this site, you consent to our use of cookies.