Home › Forums › General Issues › Unable to write multiple values back to ACF user field › Reply To: Unable to write multiple values back to ACF user field
Some additional information:
The match_mentor & match_mentee and current_mentees are all ACF fields.
I am able to manually add (mentee) users (single & multiple) to the current_mentees through the dropdown in the user account. It appears as an array of arrays.
The first one looks like: a:1:{i:0;s:2:”60″;}
Adding the second one gives me: a:2:{i:0;s:2:”60″;i:1;s:2:”57″;}
This is functional for my purpose. I’d like the code to do the same.
Using the above code to add one user, in the current_mentees field/DB I see 60.
And then adding the 2nd one, I get a:1:{i:0;i:57;}. (It replaces the first one).
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.