I would like to display a text depends of my custom taxonomy category, like:

if custom post type category is X, then echo Text Y.

I’ve tried this, but its not working:

global $post; 
if (($post->post_type == 'myposttype') && is _category('slug-name-of-cat')) {
 echo 'My text'
 }

any ideias?

Read more here: Conditional Statement custom post type category


Solution:

If you know the solution of this issue, please leave us a reply in Comment section, to update the question.

Related Wordpress search:

, , , , ,

Wordpress related questions and answers: