title: Wordpress: WP_Query search criteria on 'post_name'
body: <p>I'm using WP_Query (pretty standard). It all works great.</p>
  
  <p>However, I have a particular modification to make, where, if the user enters the specific post name in the URL, the search will return only the post that matches that post_name value.</p>
  
  <p>See my code below with a comment about the particular line not working.</p>
  
  <pre><code>&lt;?php
  
  $getPeople = array(
      'post_type' =&gt; 'person',
      'posts_per_page' =&gt; -1,
      // I want this below to only return me the post with this specific value.
      // This doesn't error, but doesn't work either.
      // I know it seems counter-productive to a 'search' but this particular case requires it.
      // This has a hard-coded value at the moment.
      'post_name' =&gt; 'rebecca-atkinson',
      'orderby' =&gt; 'meta_value',
      'meta_key' =&gt; 'last-name',
      'order' =&gt; 'ASC',
  
      'meta_query' =&gt; array(
          array(
              'key' =&gt; 'gender',
              'value' =&gt; $theGender,
          )
      ),
  
      'tax_query' =&gt; array(
  
          'relation' =&gt; 'OR',
  
          array(
              'taxonomy' =&gt; 'accent',
              'field' =&gt; 'slug',
              'terms' =&gt; $theAccent,
              'operator' =&gt; 'IN',
          ),
          array(
              'taxonomy' =&gt; 'style',
              'field' =&gt; 'slug',
              'terms' =&gt; $theStyle,
              'operator' =&gt; 'IN',
          ),
          array(
              'taxonomy' =&gt; 'age',
              'field' =&gt; 'slug',
              'terms' =&gt; $theAge,
              'operator' =&gt; 'IN',
          ),
  
      )
  );
  
  $myposts = new WP_Query($getPeople);
  
  ?&gt;
  </code></pre>
  
  <p>Your help would be greatly appreciated. If I could just see how to search on this specific 'slug' then that would be great. </p>
  
  <p>Many thanks,
  Michael.</p>