Home › Forums › General Issues › Taxonomy term meta › Reply To: Taxonomy term meta
I don’t, I I were going to do this I would do something like
add_action('init', 'filters_for_acf_term_meta');
function filters_for_acf_term_meta() {
$acf_version = acf_get_setting('version');
if( version_compare($acf_version, '5.5.0, '>=') ) {
// 5.5 uses term meta, don't need the filters
return;
}
// add filters and functions to deal with term meta
// you can create more than one here and they
// will only be loaded if ACF <5.5
add_action('acf/save_post', 'convert_options_to_term_meta');
function convert_options_to_term_meta($post_id) {
// use examples from
// https://support.advancedcustomfields.com/forums/topic/how-to-use-wp-term-meta-on-acf-the-easy-way/
// to build actions
} // end function convert_options_to_term_meta
} // end function filters_for_acf_term_meta
The code was edited to correct error
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.