WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have the following query along with a custom post type called "Questions":

     $args = array( 
        'post_type' => 'questions', 
        'posts_per_page' => 50 

     $loop = new WP_Query( $args ); 

     while ( $loop->have_posts() ) : $loop->the_post(); ?>
            <a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>">
                <?php the_title(); ?>
     endwhile; ?>

I've also created a custom taxonomy called "Type" and linked it to this post type in order to categorize the content (like, type of questions). This query lists all the questions title but I would like to find a way to list the categories this question belongs to so it looks like:

  1. How do I configure my email client? in "Technical Support"
  2. How to change my themes' background image in "Wordpress Support"

I've tried using but I'm not getting any results.

Any ideas?

share|improve this question
up vote 3 down vote accepted

Category is a specific taxonomy built into WordPress, the_category only works with this single taxonomy, not custom taxonomies. To fetch terms from a custom taxonomy, use the_terms:

the_terms( $post->ID, 'type' );
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.