Home › Forums › Backend Issues (wp-admin) › Updating Linked Taxonomy on Save › Reply To: Updating Linked Taxonomy on Save
So I’ve come down to this essentially.
When updating an ACF taxonomy field with update_field( "field_ID", "", $post_id)
in order to clear the field, it does NOT remove the taxonomy association in the wp_term_relationships
table.
This is with the Field Type set to Taxonomy, and the following checked:
Save Terms: Yes
Load Terms: Yes
Is there a way to unset the taxonomy field association on update_field
? Currently I know what field I want to update and the applicable taxonomy, so I can use wp_delete_object_term_relationship
against the given $post_id
, but it would be nice if update_field
took care of this for me.
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.