title: Including Custom Post Types In This Wordpress Loop
body: <p>I have 2 post types, 1 which is gaming and another which is movies that I'm trying to include in this loop that I got helped with so I'm not sure what to change:</p>
  
  <pre><code>&lt;?php if ( have_posts() ) : ?&gt;
  
  
      &lt;?php /* Start the Loop */ ?&gt;
  
      &lt;?php
      $query = new WP_Query( array( 'tag__not_in' =&gt; array( 20 ) ) );/* Exclude Tag 20 (reviews)*/
      while( $query-&gt;have_posts() ):
      $query-&gt;the_post();
  
      get_template_part( 'content', get_post_format() );
  
      endwhile;
  
      ?&gt;
  
  &lt;?php else : ?&gt;
  
      &lt;?php get_template_part( 'no-results', 'index' ); ?&gt;
  
  &lt;?php endif; ?&gt;
  </code></pre>
  
  <p>where would I include these post types?</p>
  
  <hr>
  
  <p><strong>EDIT: I updated the loop, but the page is just blank/white. heres what i have:</strong></p>
  
  <pre><code>&lt;?php if ( have_posts() ) : ?&gt;
  
  
  &lt;?php /* Start the Loop */ ?&gt;
  
  &lt;?php
  $query = new WP_Query( array( 'post_type' =&gt; array( 'movies_cp','gaming_cp'), 'tag__not_in' =&gt; array( 20 )) )
  while( $query-&gt;have_posts() ):
  $query-&gt;the_post();
  
  get_template_part( 'content', get_post_format() );
  
  endwhile;
  
  ?&gt;
  
  &lt;?php else : ?&gt;
  
  &lt;?php get_template_part( 'no-results', 'index' ); ?&gt;
  
  &lt;?php endif; ?&gt;
  </code></pre>
  
  <p>Movies Custom Post Type (using Custom Post Type UI Plugin):</p>
  
  <pre><code>register_post_type('movies_cp', array(  'label' =&gt; 'Movie Posts','description' =&gt; '','public' =&gt; true,'show_ui' =&gt; true,'show_in_menu' =&gt; true,'capability_type' =&gt; 'post','hierarchical' =&gt; false,'rewrite' =&gt; array('slug' =&gt; 'movies'),'query_var' =&gt; true,'exclude_from_search' =&gt; false,'supports' =&gt; array('title','editor','excerpt','trackbacks','custom-fields','comments','revisions','thumbnail','author','page-attributes',),'taxonomies' =&gt; array('category','post_tag',),'labels' =&gt; array (
    'name' =&gt; 'Movie Posts',
    'singular_name' =&gt; 'Movie Post',
    'menu_name' =&gt; 'Movie Posts',
    'add_new' =&gt; 'Add Movie Post',
    'add_new_item' =&gt; 'Add New Movie Post',
    'edit' =&gt; 'Edit',
    'edit_item' =&gt; 'Edit Movie Post',
    'new_item' =&gt; 'New Movie Post',
    'view' =&gt; 'View Movie Post',
    'view_item' =&gt; 'View Movie Post',
    'search_items' =&gt; 'Search Movie Posts',
    'not_found' =&gt; 'No Movie Posts Found',
    'not_found_in_trash' =&gt; 'No Movie Posts Found in Trash',
    'parent' =&gt; 'Parent Movie Post',
  ),) );
  </code></pre>