Custom taxonomy label
-
Hi all!
There is a problem with understanding how to correctly display a list of custom categories on archive pages.Initial data.
1. Created custom material type “mywork” and custom taxonomy “work-category”.
2. Created single-mywork.php and archive-mywork.php templates
3. Now, to display the categories associated with each material, the following is written in the loop
<? php the_taxonomies( '' );? >
This gives the following result:
My work category: category#1Trying to change ‘template’ does not work. Because in get_the_taxonomies() function there is a check with the substitution of the label
if ( empty( $t['label'] ) ) { $t['label'] = $taxonomy; }
How to remove “My work category” from output?
Thanks!
The page I need help with: [log in to see the link]
- The topic ‘Custom taxonomy label’ is closed to new replies.