Home › Forums › Front-end Issues › Change value when regsitering field via php based upon taxonomy selected › Reply To: Change value when regsitering field via php based upon taxonomy selected
I don’t think you can easily update the taxonomy parameter of your field once the edit screen has been rendered. It would require an AJAX call and recreating the entire field dynamically..
May I suggest a different solution that’s maybe a bit easier and doable.
If you use a relationship field instead there’s a built in filter capability for taxonomies. You can set the field to only allow for 1 value so that it’ll work pretty much the same as the post_object field.
What do you think?
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!
🚨 The 2023 ACF Annual Survey closes tomorrow! This is your last chance to complete the survey and help guide the evolution of ACF. https://t.co/0cgr9ZFOJ5— Advanced Custom Fields (@wp_acf) May 18, 2023
© 2023 Advanced Custom Fields.