Support

Account

Home Forums General Issues Display Custom Taxonomy Fields on CPT Reply To: Display Custom Taxonomy Fields on CPT

  • The first thing you need to do is get the term in the taxonomy that the post is in

    
    $terms = get_object_terms($post->ID, 'TAXONOMY SLUG HERE');
    

    this will return an array of terms that the post is in, assuming there is only one

    
    $term = $terms[0];
    

    now you can use this to get the fields from the term

    
    $value = get_field('field on term/taxonomy', 'term_'.$term->term_id;);