title: Display custom post with a custom taxonomy
body: <p>I have create a custom post type "region" with the taxonomy "region_country"</p>
  
  <pre><code>add_action('init', '_init_region_post_type');
  
  function _init_region_post_type() {
      register_taxonomy(
          'region_country',
          array( 'region' ),
          array(
              'labels' =&gt; array(
                  'name' =&gt; __( 'Countries' ),
                  'singular_name' =&gt; __( 'Country' ),
                  'search_items' =&gt; __( 'Search Countries' ),
                  'popular_items' =&gt; __( 'Popular Countries' ),
                  'all_items' =&gt; __( 'All Countries' ),
                  'parent_item' =&gt; __( 'Parent Countrie' ),
                  'parent_item_colon' =&gt; __( 'Parent Countries:' ),
                  'edit_item' =&gt; __( 'Edit Countrie' ),
                  'update_item' =&gt; __( 'Update Countrie' ),
                  'add_new_item' =&gt; __( 'Add New Countrie' ),
                  'new_item_name' =&gt; __( 'New Countrie' ),
              ),
              'public' =&gt; true,
              'show_in_nav_menus' =&gt; true,
              'show_ui' =&gt; true,
              'publicly_queryable' =&gt; true,
              'exclude_from_search' =&gt; false,
              'hierarchical' =&gt; true,
              'query_var' =&gt; true,
          )
      );  
  
  
      register_post_type( 'region',
          array(
              'capability_type' =&gt; 'post',
              'hierarchical' =&gt; false,
              'public' =&gt; true,
              'show_ui' =&gt; true,
              'publicly_queryable' =&gt; true,
              'exclude_from_search' =&gt; false,
              'menu_position' =&gt; 30,
              'labels' =&gt; array(
                  'name' =&gt; __( 'Regions' ),
                  'singular_name' =&gt; __( 'Region' ),
                  'add_new' =&gt; __( 'Add New' ),
                  'add_new_item' =&gt; __( 'Add New Region' ),
                  'edit' =&gt; __( 'Edit Region' ),
                  'edit_item' =&gt; __( 'Edit Region' ),
                  'new_item' =&gt; __( 'New Region' ),
                  'view' =&gt; __( 'View Region' ),
                  'view_item' =&gt; __( 'View Region' ),
                  'search_items' =&gt; __( 'Search Region' ),
                  'not_found' =&gt; __( 'No regions found' ),
                  'not_found_in_trash' =&gt; __('No regions found in Trash')
              ),
              'has_archive' =&gt; true,
              'supports' =&gt; array('title', 'page-attributes', 'editor', 'excerpt', 'thumbnail', 'custom-fields'),
              'query_var' =&gt; true,
  
          )
      );
  
  }
  </code></pre>
  
  <p>Inside the taxonomy "region_country", I had created "china" and "laos" as categories or tag (don't know?)</p>
  
  <p>I would like to display only posts from the taxonomy "region" where I had the tag/category "China"</p>
  
  <p>This is what I have done:</p>
  
  <pre><code> &lt;?php
  
  $type = 'region';
  $args=array(
    'post_type' =&gt; $type,
    'post_status' =&gt; 'publish',
    'posts_per_page' =&gt; -1,
    'caller_get_posts'=&gt; 1,
    'cat' =&gt; 'China' 
    );
  
  $my_query = null;
  $my_query = new WP_Query($args);
  if( $my_query-&gt;have_posts() ) {
      while ($my_query-&gt;have_posts()) : $my_query-&gt;the_post();
  
      if (has_post_thumbnail()) {
          echo "&lt;a href=\""; echo the_permalink(); echo "\" title=\""; echo the_title_attribute(); echo "\" rel=\"external\" &gt;";
              echo "&lt;div class=\"thumbnail_image_related_project visible\"&gt;";
                  echo "&lt;div class=\"image\"&gt;";
                      echo the_post_thumbnail();
                  echo "&lt;/div&gt;";
                  echo "&lt;h2 class=\"transparent_font\"&gt;";
                      echo "&lt;div id=\"indent_text\"&gt;";
                          echo the_title(); 
                      echo "&lt;/div&gt;";
                  echo "&lt;/h2&gt;";
              echo "&lt;/div&gt;";
          echo "&lt;/a&gt;&lt;div style=\"height:50px;\"&gt;&lt;/div&gt;";
      }
      else
      {
          echo "&lt;a href=\""; echo the_permalink(); echo "\" title=\""; echo the_title_attribute(); echo "\" rel=\"external\" &gt;";
              echo "&lt;div class=\"thumbnail_image_related_project visible\"&gt;";
                  echo "&lt;div class=\"image\"&gt;&lt;img width=\"624\" height=\"468\" src=\"http://www.cvdfk.com/images/missing_image.gif\" class=\"attachment-post-thumbnail wp-post-image\" alt=\"china-5-624x468\"&gt;";
                  echo "&lt;/div&gt;";
                  echo "&lt;h2 class=\"transparent_font\"&gt;";
                      echo "&lt;div id=\"indent_text\"&gt;";
                          echo the_title(); 
                      echo "&lt;/div&gt;";
                  echo "&lt;/h2&gt;";
              echo "&lt;/div&gt;";
          echo "&lt;/a&gt;&lt;div style=\"height:50px;\"&gt;&lt;/div&gt;";                      
      }
      endwhile;
  }
  wp_reset_query();  // Restore global post data stomped by the_post().
  ?&gt;
  </code></pre>
  
  <p>Thanks</p>