Home › Forums › General Issues › dependent dropdown select field › Reply To: dependent dropdown select field
Just a note, this may not always work.
var acf_field = acf.getField('field_56e1cf2e7ad26');
acf_field.on("change ready", function(e){
The reason being that it will not work on fields that are dynamically added after the page is loaded. In one of the sites I’m working on I needed to do something like this
$(document).on('change', '[data-key="field_5b6c628cb8088"] .acf-input input', function(e) {
// ...
});
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.