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 set up a CPT, lets say "Movies".

'rewrite'   => array( 'slug'=>'movies', 'with_front'=>FALSE )

I added a taxonomy "Genre".

'rewrite'   => array( 'slug'=>'movies/genre', 'with_front'=>FALSE )

I also tried

'rewrite'   => array( 'slug'=>'genre', 'with_front'=>TRUE )

register_taxonomy( 'category_movie', 'movie', $args );

Everything works, but, when I want to browse some movies e.g. in the category/taxonomy horror it does not work.

I assumed the file taxonomy-category_movie.php and if not then taxonomy.php





BUT NO! WP always falls back to the index.php file.

So I though I will check what WP actually is doing and added

if ( is_home() )
echo "<br>IS HOME";

if ( is_single() )
 echo "<br>IS SINGLE";

if ( is_singular() )
 echo "<br>IS SINGULAR";

if ( is_front_page() )
 echo "<br>IS FRONT PAGE";

if ( is_page() )
 echo "<br>IS PAGE";

if ( is_category() )
 echo "<br>IS CATEGORY";

if ( is_tag() )
 echo "<br>IS TAG";

if ( is_tax() )
 echo "<br>IS TAX";

but none of the messages made it into the browser....

Hopefully somebody knows the answer!!

share|improve this question

There's a giant diagram on the wordpress documentation showing how it chooses which file to display/load, as you can see here:


alt text

If this doesn't help, my other suggestion is trying with the '_' removed from the taxonomy name, and to test with the rewrite option removed from your custom post type declaration. In my experience wordpress is fidgetty about type names that add punctuation so I try to keep to a singular word or Camel case. You may have more success with a "genre" taxonomy

share|improve this answer

Your Answer


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