taxonomy; // Single Category ID $term_id = $queried_object->term_id; $term_name = $queried_object->name; $term_link = get_term_link($term_id, $taxonomy); // Parent Category ID $parents_id = get_ancestors( $term_id, $taxonomy); $parents_id = array_reverse($parents_id); ?>

name; // Single Custom ID $term_id = $queried_object->term_id; $taxonomy = $queried_object->taxonomy; $term_link = get_term_link($term_id, $taxonomy); // Parent Custom ID $parents_id = get_ancestors( $term_id, $taxonomy); $parents_id = array_reverse($parents_id); ?>