Home › Forums › Add-ons › Repeater Field › Repeater rows don't save new files › Reply To: Repeater rows don't save new files
I actually was using the field key at first. I switched to “documents” in an effort to debug. I put it back to the field key for the below test. Anyway, printing the $value array gives me back an array with all the rows of the repeater, as expected.
Array
(
[0] => Array
(
[file] =>
[file_description] =>
[file_user] =>
[file_date] =>
[file_phase] =>
)
)
Sorry, truncated the values for space. The values were all exactly as expected for the existing file. A URL for the file itself, text for description, User object for user, @ format for date, and WP Object for phase. Totally good.
Doing the same thing after the $value[], however, shows the above row correctly, and then the row I am trying to add like this:
[2] => Array
(
[file] => 414
[file_description] =>
[file_user] => 1
[file_date] => 1374226973000
[file_phase] => 232
)
So instead of objects and URLs, it’s showing the ID of the item I am about to insert, I guess. Is this appropriate? Just making sure.
I’m kind of at a loss. It’s still deleting the previous file ID. Everything else remains when I add a row – description, user, date, phase. The only thing deleted from previous rows is the file.
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.