get custom category by name and display the custom post_type
-
I have a custom post_type
register_post_type('specials', $items); register_taxonomy('type', array('specials'), array('hierarchical' => true, 'label' => 'Type', 'singular_label' => 'Type', 'show_ui' => true, 'query_var' => true, 'rewrite' => true));I have problem with getting a post from a specific category “type”.
with
<?php query_posts('post_type=specials') ?>i get all the post from the post_type specials, but that is not what i need.in the category type i added Item1 and item2, slugname are item-1 , item-2
i need to get the category/taxonomy of type by slugname (item-1)and then display all the relevant post of it. but i cant find the correct code for it.
Can someone throw me a good example ?
Thanks!
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
The topic ‘get custom category by name and display the custom post_type’ is closed to new replies.