display multiple term post from taxonomy in a single page

Thank you for your time answering my unclear question. The code I found is the one that Im looking for. Thank you again 🙂 <?php //http://codex.wordpress.org/Function_Reference/WP_Query#Taxonomy_Parameters $term_slug = get_queried_object()->slug; if ( !$term_slug ) return; else $args = array( ‘tax_query’ => array( array( ‘taxonomy’ => ‘gallery_category’, ‘field’ => ‘slug’, ‘terms’ => $term_slug, ‘posts_per_page’ => 10 ) … Read more

Custom Post Status not showing in Custom Post Type ALL view

You should set the public argument to true. This way the post with ‘inpacking’ or ‘sent’ post_status will also show in total. So your code should be like this: register_post_status( ‘inpacking’, array( ‘label’ => _x( ‘In Packing’, ‘Order packing’ ), ‘public’ => true, ‘exclude_from_search’ => false, ‘show_in_admin_all_list’ => true, ‘show_in_admin_status_list’ => true, ‘label_count’ => _n_noop( … Read more

Custom post type permalink structure with the category also acting as an archive

I should have looked a little closer at that link posted. There was a link in that question that contained the answer (https://wordpress.stackexchange.com/a/5313/100538). Below is the code I used to get the effect I need: ///// CUSTOM POST TYPES ///// // register the new post type register_post_type( ‘business’, array( ‘labels’ => array( ‘name’ => __( … Read more

Is it possible to have an index page for taxonomy term for each custom post type it is assigned to?

A simple method would be to create a archive template file for the location taxonomy, and then include the proper inner-template for each post type. First, create a PHP file in your theme’s root folder, named taxonomy-location.php. Then, you can use get_post_type() insider this template the include the proper template: get_template_part( ‘templates’, get_post_type() . ‘-content’ … Read more

Get latest 4 post on a custom post filtered by category

There should be no difference and either custom WP_Query or wp_get_recent_posts should work like a charm in this case. (To be honest, wp_get_recent_posts uses get_posts and this one is based onWP_Query`). So the problem is not with methods you’re trying to use, but the way you use them… wp_get_recent_posts wp_get_recent_posts function takes two arguments: $args … Read more