Get Categories Where Taxonomy Equals ‘n’

get_categories() only lists categories, so you shouldn’t be seeing any terms from the custom taxonomy. What you want to use is get_terms() which takes a taxonomy as an argument. As you can read about in this answer, get_terms() is actually used by get_categories(), it just prefills the “taxonomy” argument with “category.” If you swap in … Read more

previous_post_link in same taxonomy in custom post type

I’d suggest using a plugin for this. next_post_link and previous_post_link will use the category taxonomy (literally)*, so they will not work as expected with custom taxonomies, which I think you are using here. I’ve used both Smarter Navigation by Scribu and Ambrosite Next/Previous Post Link Plus, which are both great plugins for this sort of … Read more

Proper WP conditional tag to check for existing taxonomies to list out terms with wp_list_categories?

is_tax() returns true on a taxonomy archive page, it has nothing to do with whether terms exist in a taxonomy. you just need to add a check for anything returned from wp_list_categories before outputting any markup: <?php $args_list = array( ‘taxonomy’ => ‘productcategory’, ‘title_li’ => __(”), ‘show_count’ => false, ‘hierarchical’ => true, ‘echo’ => ‘0’, … Read more

portfolio custom type tags support

Just add this code under your category registration. Check the register_taxonomy() function for more details. Usually when you set hierarchical => true taxonomy looks like category and hierarchical => false its looks like tag. register_taxonomy(‘portfolio_tag’,’portfolio’,array( ‘hierarchical’ => false, ‘labels’ => array( ‘name’ => _x( ‘Portfolio Tags’, ‘taxonomy general name’, ‘flowthemes’ ), ‘singular_name’ => _x( ‘Portfolio … Read more