Home › Forums › Backend Issues (wp-admin) › Taxonomy not saving on Attachment › Reply To: Taxonomy not saving on Attachment
I realise I am necroposting, but I found this answer useful and wanted to post a small improvement.
The first function remove_custom_taxonomy
can be eliminated if meta_box_cb
is set to false
when making the initial register_taxonomy
call.
Or, if you don’t have control of the registration, you can filter the args later:
function removeTaxonomyInEditor($args, $taxonomy)
{
if ($taxonomy === 'INSERTYOURTAXONOMYNAME') {
$args['meta_box_cb'] = false;
}
return $args;
}
add_filter('register_taxonomy_args', removeTaxonomyInEditor, 10, 2);
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.