Yes it works – it works with a little bit knowledge using the perfect example from Hube – but it works also with standard ACF functions. You should use a standard select field with UI and AJAX activated. Your PHP action load_field should be set for this field and load the correct data. This is for both fields. Your second field should “hear” on $_POST[‘your_var_brand’] and then you should do a little bit work on your JS file…..
acf.addFilter('select2_ajax_data', function( data, args, $input, field, instance )
I have used this in my actual plugin project in 15 fields and it works great.
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!
© 2023 Advanced Custom Fields.