Okay I have a pretty crispy workaround, but it works.
I am using ACF Pro 5.7.11
In the old thread find the first reply by shaun where he has a code block. Here’s the link:
Use that code in functions.php or wherever.
In ACF setup whatever custom fields you need, but in the rule select product instead of product_variation because that option isn’t present.
Go to the ACF Tools page and export the .json of your custom fields. Open that file with a text editor and scroll down to the “locations” section. Simply change the “value” from “product” to “product_variation” and then on that same tools page re-upload the file. You should see custom fields in your product variations drop downs now on variable products.
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!
© 2022 Advanced Custom Fields.