Found this code at the official WordPress Function Reference:
A simple way to get all archive-linked terms of one Taxonomy.
List all the terms, with link to term archive, separated by an interpunct (·):
$args = array( 'hide_empty=0' );
$terms = get_terms('my_term', $args);
if ( !empty( $terms ) && !is_wp_error( $terms ) ) {
$count = count($terms);
$i=0;
$term_list="<p class="my_term-archive">";
foreach ($terms as $term) {
$i++;
$term_list .= '<a href="' . get_term_link( $term ) . '" title="' . sprintf(__('View all post filed under %s', 'my_localization_domain'), $term->name) . '">' . $term->name . '</a>';
if ($count != $i) {
$term_list .= ' · ';
}
else {
$term_list .= '</p>';
}
}
echo $term_list;
}
Related Posts:
- Listing Custom Post Post from certain category
- List a custom post type’s posts ordered by nested custom taxonomy
- How to get all taxonomies of a post type?
- Renaming Custom Post Types and Taxonomies
- Saving Taxonomy Terms
- Get Posts by Custom Post Type ,Taxonomy, and Term
- How to change permalink structure for custom post type and it’s taxonomies?
- How do I list custom taxonomy terms without the links?
- How to list custom taxonomy categories?
- Custom Taxonomy Template Post List with Sort Order
- wp_insert_term doesn’t work with custom post type’s taxonomy
- Order Posts by Taxonomy and Meta Value
- Get the ‘slug’ of a custom taxonomy
- Taxonomy page returns 404 page not found
- It is possible to get a list of post types asociated to a taxonomy?
- display multiple term post from taxonomy in a single page
- Custom Metabox with Taxonomy Dropdown – Saving Issue
- How to get the parent’s taxonomy?
- Adding a term name from a custom taxonomy assigned to a post link displayed by a wp_query loop based on another taxonomy
- Group Custom post type in a page by its taxomony tag
- create a back-end wordpress content submission using custom post type
- Same base slug for CPT post and CPT taxonomy terms
- wp_insert_post custom taxonomy
- Displaying related posts in a custom post type by a custom taxonomy
- Display taxonomy term only if there’s a value
- Post Link Filter Help [closed]
- Custom Post Types and Categories?
- Problem with custom post types, taxonomy and permalinks
- How to create new category for custom post type?
- Fetch taxonomies by custom post type id array
- get_terms showing all categories instead of the ones assigned to a specific post
- Why does querying on post_tags (which has been applied to custom post types) only return posts?
- Order By Post Type ThenBy Taxonomy
- How to show CPTs in term archive
- Custom query to filter posts that have current post as a taxonomy [closed]
- Tag page with Custom Post Types not returning any posts
- wp_set_object_terms() not adding new term to custom post and custom taxonomy
- Is using taxonomies the way to go here or would custom post types be better?
- Categories of custom taxonomy don’t show any posts
- Custom Taxonomy back-end customizations
- Is it possible to have dedicated page for parent/child taxonomy?
- Display a grid of taxonomy terms at root taxonomy page
- limit value taxonomy based on previous taxonomy value wordpress
- Using meta_query and tax_query at the same time
- How to make custom taxonomy into drop down select in a custom metabox
- How to display products name in a non-alphabetical order, in a custom field (taxonomy)?
- Taxonomy in URL
- How to organise this data within WordPress
- How to Set Taxonomy Object Description?
- Custom select query for taxonomies that have posts categorized in another taxonomy
- How to assign tag to custom post type in wordpress?
- Variable not working in WP_Query
- Associate all Custom Post Types with Taxonomy
- Alphabetically sort a taxonomy.php template by post title
- Show Taxonomies with admin area for custom post type?
- Custom taxonomy template list not working (404)
- Use the custom post type archive for taxonomies?
- Taxonomy template page not working
- Copy/Move selected taxonomy terms to another taxonomy for posts
- Running a custom query inside another cpt single and trying to grab a variable
- Get posts by category name
- Get post-meta value of all custom-posts – lowest to highest year-count?
- Query Custom Post Type by Taxonomy
- Copying over taxonomy structure from one CPT to another
- Sort Archive by Taxonomy
- Query all posts under one taxonomy? Why is my code not working?
- Display ONE taxonomy and its assigned pages
- CPT archive with WP native/core tax/categories
- Page that lists publications by classifying them by taxonomy
- Order posts by taxonomy terms
- How can i display a taxonomy? i have created a plugin and then a custom type. and a taxonomy , also i have register it
- Filtering posts based on three taxonomies
- Display category filters for custom post type when category is shared by multiple post types
- How to order taxonomy terms by most recent post?
- editing shortcode for custom post type within a plugin
- Taxonomies are not showing in the category dropdown
- How to display all terms from all taxonomies in post, but separately for each taxonomy?
- Change custom post taxonomy values from front-end
- List all posts associated under custom taxonomy
- Custom Taxonomy – fields
- Pages of my taxonomy terms are showing all posts
- Custom post type category link + add to menu
- One of my headings is mysteriously coming up as a link in my CPT Archive
- Single taxonomy for different custom post types
- Reuse the “category” slug for a custom post type
- Taxonomy and Custom Post type with Collpase
- Best approach to allow front-end display of posts’ reviewers?
- Custom Post Type and Taxonomies, creating the corresponding template file and loop the data
- Custom Post Type parent slug as menu item
- Displaying taxonomy icon outside archive page
- Taxonomy Grid Archive Help?
- Query Distinct Taxonomies of Custom Post Type
- Show taxonomies from specific CPT
- Using a Taxonomy in Two Spots in a WordPress Post
- insert a taxonomy for a custom post type
- Custom Post Type Template based on Taxonomy
- Author template – separate custom post type by custom taxonomy term for $curauth
- custom post type tags
- See the process of creating a taxonomy and tell me where I made a mistake
- Taxonomy Archive URL + Template