title: Custom post type not displaying in custom wp query loop
body: <p>I'm trying not to repeat questions that've already been asked but I haven't been able to debug this so far - I'm sure it's a small thing I'm missing!</p>
  
  <p>I have a single-project.php template that I'd like to include a sidebar with all project custom post types as links. I only seem to be getting 'post' post_type, not my custom post_type (project)</p>
  
  <p>Registered custom post type in functions.php</p>
  
  <pre><code>function custom_post_type() {
  $labels = array(
  'name'                  =&gt; _x( 'Project', 'Post Type General Name', 'text_domain' ),
      'singular_name'         =&gt; _x( 'Project', 'Post Type Singular Name', 'text_domain' ),
      'menu_name'             =&gt; __( 'Projects', 'text_domain' ),
      'name_admin_bar'        =&gt; __( 'Projects', 'text_domain' ),
      'archives'              =&gt; __( 'Item Archives', 'text_domain' ),
      'attributes'            =&gt; __( 'Item Attributes', 'text_domain' ),
      'parent_item_colon'     =&gt; __( 'Parent Item:', 'text_domain' ),
      'all_items'             =&gt; __( 'All Projects', 'text_domain' ),
      'add_new_item'          =&gt; __( 'Add New Item', 'text_domain' ),
      'add_new'               =&gt; __( 'Add New', 'text_domain' ),
      'new_item'              =&gt; __( 'New Item', 'text_domain' ),
      'edit_item'             =&gt; __( 'Edit Item', 'text_domain' ),
      'update_item'           =&gt; __( 'Update Item', 'text_domain' ),
      'view_item'             =&gt; __( 'View Item', 'text_domain' ),
      'view_items'            =&gt; __( 'View Items', 'text_domain' ),
      'search_items'          =&gt; __( 'Search Item', 'text_domain' ),
      'not_found'             =&gt; __( 'Not found', 'text_domain' ),
      'not_found_in_trash'    =&gt; __( 'Not found in Trash', 'text_domain' ),
      'featured_image'        =&gt; __( 'Featured Image', 'text_domain' ),
      'set_featured_image'    =&gt; __( 'Set featured image', 'text_domain' ),
      'remove_featured_image' =&gt; __( 'Remove featured image', 'text_domain' ),
      'use_featured_image'    =&gt; __( 'Use as featured image', 'text_domain' ),
      'insert_into_item'      =&gt; __( 'Insert into item', 'text_domain' ),
      'uploaded_to_this_item' =&gt; __( 'Uploaded to this item', 'text_domain' ),
      'items_list'            =&gt; __( 'Items list', 'text_domain' ),
      'items_list_navigation' =&gt; __( 'Items list navigation', 'text_domain' ),
      'filter_items_list'     =&gt; __( 'Filter items list', 'text_domain' ),
  );
  $args = array(
      'label'                 =&gt; __( 'Project', 'text_domain' ),
      'description'           =&gt; __( 'Spaceworks projects', 'text_domain' ),
      'labels'                =&gt; $labels,
      'supports'              =&gt; array( ),
      'hierarchical'          =&gt; false,
      'public'                =&gt; true,
      'show_ui'               =&gt; true,
      'show_in_menu'          =&gt; true,
      'menu_position'         =&gt; 5,
      'show_in_admin_bar'     =&gt; true,
      'show_in_nav_menus'     =&gt; true,
      'can_export'            =&gt; true,
      'has_archive'           =&gt; true,        
      'exclude_from_search'   =&gt; false,
      'publicly_queryable'    =&gt; true,
      'capability_type'       =&gt; 'post',
  );
  register_post_type( 'project', $args );
  
  }
  add_action( 'init', 'custom_post_type', 0 );
  </code></pre>
  
  <p>Register custom taxonomy in functions.php</p>
  
  <pre><code>function my_taxonomies_project() {
  $labels = array(
  'name'              =&gt; _x( 'Project Categories', 'taxonomy general name' ),
  'singular_name'     =&gt; _x( 'Project Category', 'taxonomy singular name' ),
  'search_items'      =&gt; __( 'Search Project Categories' ),
  'all_items'         =&gt; __( 'All Project Categories' ),
  'parent_item'       =&gt; __( 'Parent Project Category' ),
  'parent_item_colon' =&gt; __( 'Parent Project Category:' ),
  'edit_item'         =&gt; __( 'Edit Project Category' ), 
  'update_item'       =&gt; __( 'Update Project Category' ),
  'add_new_item'      =&gt; __( 'Add New Project Category' ),
  'new_item_name'     =&gt; __( 'New Project Category' ),
  'menu_name'         =&gt; __( 'Project Categories' ),
  );
  $args = array(
  'labels' =&gt; $labels,
  'hierarchical' =&gt; true,
  );
  register_taxonomy( 'project_category', 'project', $args );
  }
  add_action( 'init', 'my_taxonomies_project', 0 );`
  </code></pre>
  
  <p>Single project template: single-project.php</p>
  
  <pre><code>&lt;?php
  get_header();
  
  while ( have_posts() ) : the_post(); ?&gt;
  
  &lt;div class="projects"&gt;
  &lt;?php the_title( '&lt;h1 class="entry-title"&gt;', '&lt;/h1&gt;' ); ?&gt;
  &lt;?php the_content(); ?&gt;
  &lt;/div&gt;
  
  &lt;?php 
  endwhile; 
  wp_reset_query();
  ?&gt;
  
  
  &lt;div class="col-12 col-lg-3 col-xl-3 hidden-lg-up allProjects"&gt;
  #project loop for mobile
  
  &lt;?php
  $tax_query_args = array(
      array(
          'post_type'         =&gt; array('post', 'project'),
       ),
  );
  
  $taxQuery = new WP_Query( $tax_query_args ); 
  
  if ($taxQuery-&gt;have_posts())
  while ($taxQuery-&gt;have_posts() ) : $taxQuery-&gt;the_post(); 
  ?&gt;
  
  &lt;div class="projectCard"&gt;
  &lt;a href="&lt;?php echo get_permalink(); ?&gt;"&gt;
  &lt;p&gt;&lt;?php the_title() ?&gt;&lt;/p&gt;
  &lt;/a&gt;
  &lt;/div&gt;
  
  &lt;?php endwhile; wp_reset_query(); 
  
  get_footer();
  ?&gt;
  </code></pre>
  
  <p>Can anyone spot an issue? This has been bugging me for a few days!
  All the best</p>