Latest Post

Display current taxonomy term when inside custom post type

Display current taxonomy term when inside custom post type

Display current taxonomy term when inside custom post type


This code for you can use for current taxonomy term when inside all custom post type.

foreach (get_the_terms(get_the_ID(), 'unlimited') as $cat) {
echo '<p>';
echo '<a href="' . esc_url( get_term_link( $cat ) ) . '" >' . $cat->name . '</a>';
echo '</p>';

}

No comments