Custom taxonomy template loop

The way I read you question is that you need 12 posts per page in this taxonomy regardless of the current term been displayed. This can be easily done with pre_get_posts. You should never change the main query for a custom query on archive pages. Have a read on this answer I’ve recently done on … Read more

Show all custom post type posts sorted by custom taxonomy then by another custom taxonomy

First get a list of categories and a list of locations. Then loop through each category. Within each category loop through the list of locations and query posts that have the current category and the current location and output the list: $categories = get_terms( array( ‘taxonomy’ => ‘shop_category’, ) ); $locations = get_terms( array( ‘taxonomy’ … Read more

Get current page’s taxonomy

Like Rarst, I am confused what you want to output, the taxonomy or the terms of that taxonomy. Taxonomy can be output for example if you make a template file with the name of that taxonomy: taxonomy-name.php the title of the taxonomy then becomes: <h1 class=”page-title”><<?php $term = get_term_by( ‘slug’, get_query_var( ‘term’ ), get_query_var( ‘taxonomy’ … Read more

Define permalinks for custom post type by taxonomy in WP 3.4

Solution I have figured it out with the help of these posts by Jan Fabry -> https://wordpress.stackexchange.com/a/5478/10350 https://wordpress.stackexchange.com/a/22490/10350 I have set up the custom post type as follows -> Custom post type (register_post_type) -> “product” Taxonomy (register_taxonomy) -> “product-type” Back-end function I rewrite the permalink structure that is saved in the back-end, so that the … Read more

How to include parent terms in hierarchical taxonomy URLs?

Just clarifying, what was pointed out by Parst with a working example of a custom taxonomy registration code: $labels = array( ‘name’ => _x( ‘Issue numbers’, ‘taxonomy general name’, ‘sascha_setup_post_type’ ), ‘singular_name’ => _x( ‘Issue number’, ‘taxonomy singular name’, ‘sascha_setup_post_type’ ), ‘search_items’ => __( ‘Search issues’, ‘sascha_setup_post_type’ ), ‘all_items’ => __( ‘All issue numbers’, ‘sascha_setup_post_type’ … Read more