Home › Forums › Backend Issues (wp-admin) › Populate select list with contents from another select list in admin › Reply To: Populate select list with contents from another select list in admin
Hi @blakespot
You can use the acf/load_field
hook to do that, but you need to save the post and the first repeater field first before it showing up on the second repeater field. This page should give you more idea about it: https://www.advancedcustomfields.com/resources/dynamically-populate-a-select-fields-choices/.
If you don’t want to save the post first, you need to use advanced Javascript code to achieve it. This page should give you more idea about it: https://www.advancedcustomfields.com/resources/adding-custom-javascript-fields/. I believe you can use the acf.add_action('append', function( $el ){
action to check the new row in the second repeater and then update it with the data from the first repeater.
I hope this helps 🙂
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.