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 one wordpress theme which contain Custom Post Type.

And in my theme I can add that as a page which show some different URL.

Now when I call a WP function (is_page('some-page')) for wordpress page so this code is working.

Now for my Custom page I write that same code but it's not working.

So my question is how can we call this kind of specific custome page in wordpress.

share|improve this question

migrated from stackoverflow.com Sep 22 '12 at 22:44

This question came from our site for professional and enthusiast programmers.

up vote 1 down vote accepted

Please check Wordpress theme hierarchy and you will know which file you need to create for custom post types :-)


Most likely you are after archive-$posttype.php

share|improve this answer
Thanks for your replay, This is exactly what I want thanks a lot. – wasim kazi Sep 19 '12 at 10:08
try get_post_type( $post->ID ) == "[YOUR POST TYPE]" – Merca Sep 19 '12 at 10:11
is_single is work in my case – wasim kazi Sep 19 '12 at 10:17

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.