Home › Forums › ACF PRO › Duplicate values not uploading to select field › Reply To: Duplicate values not uploading to select field
There isn’t a way around this directly. The reason this happens is that ACF stores the values as an array, like this
$field['choices'] = array(
2850 => 'Aarons Pass'
2176 => 'Abbotsbury'.
2046 => 'Abbotsford',
2795 => 'Abercrombie',
2795 => 'Abercrombie River',
2325 => 'Aberdare',
2359 => 'Aberdeen',
2336 => 'Aberdeen',
2350 => 'Aberfoyle',
)
anywhere you have two array indexes of the same value some of them will be cancelled out.
I’d suggest using values like ‘2759-1’, ‘2795-2’, or something else that will uniquely identify them and then deal with this in your PHP code.
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.