Home › Forums › Backend Issues (wp-admin) › Dynamically Loading Values From Adjacent Fields › Reply To: Dynamically Loading Values From Adjacent Fields
Hi John,
Yes, so once the user has saved a questionnaire they’re then able to edit the list of questions to add dependencies between questions.
I added if(!isset($_GET['post'])) return array();
so that the code wouldn’t try running if the post didn’t have an ID (ie. when it’s a new post – since then there wouldn’t be any custom fields to find, since the post would have never been saved).
Also, to elaborate on what happens, as soon the edit page gets to the repeater field containing the select the code breaks and no more PHP appears to be processed. There are no errors in the log, however.
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.