As far as I’m aware, your question has been answered here.
You’re getting the singular_name correctly, all you need to do is echo it.
<?php $taxonomies = get_object_taxonomies( $post );
foreach ( $taxonomies as $taxonomy ) {
$term_name = $taxonomy->labels->singular_name;
echo $term_name;
the_terms( $post->ID, $taxonomy, '<span class="e-article__category__item"><strong>' . $term_name . ': </strong> ', ", ", '</span>' );
} ?>
Related Posts:
- Custom post type for ‘staff’ versus using wordpress user profiles?
- What are the differences between custom post type and custom page templates?
- How to get custom post type label and singular label from its slug?
- next_post_link() not working for single custom post type post
- How to set a default format for a custom post type?
- Now can I group custom post types together?
- Does anyone have any frameworks to setup custom post types and related actions/filters?
- Exclude add_filter from the admin
- Sanitizing post content for use in an email
- Query multiple taxonomy in Custom Post Type
- automatically create taxonomy with same name as post title
- saving custom post type data to different table in wordpress
- Create Custom Post Type Archive Page with Sub Categories Navigation Sidebar
- register_post_type – rewrite / feeds, what’s it for?
- WordPress import not importing custom taxonomy
- Why are navigation items saved in the database?
- Filter posts with meta_query NOT IN where value has multiple values
- WP 4.7 broke get_post_type or requires an explicit integer value?
- Remove base slug in permalinks of hierarchical custom post type
- How to show the archive / post type description on Single templates
- is_main_query() not working for WP REST API
- How can I move a custom taxonomy and its data from one post type to another?
- Show listings from Impress Listing plugin in random order using taxonomy and terms
- Get next and previous 3 posts in a term in single post page
- Can’t edit custom post type
- redirecting improperly after updating custom taxonomy term when referring from CPT edit page
- Deleting Custom Posts & Meta Data on Uninstall
- I’d like to cycle through existing posts in a post type, showing one per day ordered by title, and starting over when the last is reached
- WooCommerce Customer Role Delete Custom Post Type
- Options page – dropdown of users
- Addition of custom option panel crashes Media Library & Admin Area
- CPT’s with landing page instead of archive – Url Rewrite?
- How to produce a sub-page-system in WordPress
- Remove “show sharing buttons” metabox Jetpack from custom post type
- How can I add a filter to a particular post format?
- Custom post type causes php-error in php version 5.2.17
- How do you make a custom post type items automatically delete items 3 months after publication?
- Custom Post Type Metadata Not Saving
- get_post_meta is not working inside shortcode
- False Positive on has_post_thumbnail
- Custom Meta Box Causing Error: “Are you sure you want to do this? Please try again.”
- Iterating through Object Array to customise display of full custom taxonomy for custom post type
- When I choose category from dropdown then everything working fine.But in backend it checked only child not parent [closed]
- Keep getting logged out
- Enable comments on custom page type – option not showing in “customize” for theme
- How to migrate Custom Field Template to a WordPress Multisite
- How to Query in WordPress which shows Alphabetic Posts?
- Using breadcrumb to return from single-page to list
- How can I lock specific posts (cpt’s) from editing by anyone other than ADMINS
- Why do I need to register my custom post type a second time when flushing rewrite rules?
- How do I Query 2 Custom Post Types?
- Function to erase every post from a taxonomy
- Custom Post Type or Shortcode, What to choose? [closed]
- Building a Data Intensive Website with WordPress
- Change permalink for custom post type?
- Use Author Ids or Names to echo different output inside loop
- Truncate custom post type content
- Add parameters to Yoast SEO plugin schema in functions.php [closed]
- Use a different URL path / permalink for CPT
- Group episodes by seasons
- allowing custom user role to access custom post type in wordpress admin
- Page not found on custom post type page for projects
- Why this didn’t work if i use get_the_ID(), but works if i pass the numeric id
- Archive for custom taxonomy
- How can we display full post on home page rather than excerpt
- Rewrite of Custom Post Type doesn’t work with dynamic data
- Make pagination work as a carousel (custom query)
- WooCommerce change
- Custom post types & Advanced Custom Fields code is not working
- Working with Custom Post Type
- Question on templates
- Custom taxanomy and custom post type – pagination leads to 404
- How can I load Template file from wordpress plugin
- Getting all custom post taxonomies and exhibiting only part of them
- Author archive custom posts only?
- update a posts of other custom post type
- Custome post type “tags” pick default archive instead of custom post type archive
- How to return custom posts in loop?
- Custom post type AND custom taxonomy are not connected
- How to delete comma from the end of results? [closed]
- Front end page submission form does not attach custom post type
- Pagination custom post types outside loop
- How do I get a nested query to only display content that the main query outputed
- Single page archive – get coresponding taxonomy and terms
- Custom WordPress URL
- Get post id of permalink for a specific custom post type?
- Displaying custom post types with taxonomy
- If you’re calling a dynamic css inline style does that div have to be in the loop?
- If i have custom post type with 5 custom fields do i have to create a new loop to reference each one?
- Add taxonomy to custom post type archive
- Custom taxonomy archive not showing posts of certain child taxonomies
- How to show animal lineage/pedigree in WordPress?
- WP_Query arguments: Loop through custom post type – get all entries except excluded meta_key?
- Custom Post Type Loop breaking php
- Order custom post type is beign ignored
- How do i get the taxonomy term name on the CPT archive page?
- is this a bug or not?
- Add a background image into a post [closed]
- Custom order of CPT posts by title, in wp-admin area by default
- Dynamically count the number of custom post types associated to a custom taxonomy