title: WordPress: multiple search terms or join results from multiple WP_Queries
body: <p>I've got the following code:</p>
  
  <pre><code>$args = array(
      's'                 =&gt; 'Apple',
      'cat'               =&gt; 80,
      'posts_per_page'    =&gt; -1,
      'orderby'           =&gt; date,
      'order'             =&gt; desc,
  );
  $query = new WP_Query( $args );
  echo $query-&gt;found_posts.'&lt;br /&gt;&lt;br /&gt;';
  if ( $query-&gt;have_posts() ) {
      while ( $query-&gt;have_posts() ) { $query-&gt;the_post();
          echo the_time("Y.m.d"); echo ': '; echo the_title(); echo '&lt;br /&gt;';
      }
  }
  </code></pre>
  
  <p>It searches category 80 for any post that contains the word <strong>Apple</strong> and then successfully outputs the list of such posts like</p>
  
  <pre><code>2
  
  2016.10.10: Apple pie
  2016.10.01: Apple juice
  </code></pre>
  
  <p>If I also want to display all the posts that contains the word <strong>Banana</strong> then I just repeat the code with <code>'s' =&gt; 'Apple'</code> replaced with <code>'s' =&gt; 'Banana'</code> and get something like</p>
  
  <pre><code>1
  
  2016.10.05: Banana fresh
  </code></pre>
  
  <p>Quite easy until I want to output both search results using the single list like</p>
  
  <pre><code>3
  
  2016.10.10: Apple pie
  2016.10.05: Banana fresh
  2016.10.01: Apple juice
  </code></pre>
  
  <p>Here I need your help as I have no idea how to achieve that.</p>
  
  <p>So far I've tried</p>
  
  <pre><code>$args = array(
      's'                 =&gt; array('Apple','Banana'),
      'cat'               =&gt; 80,
      'posts_per_page'    =&gt; -1,
      'orderby'           =&gt; date,
      'order'             =&gt; desc,
  );
  </code></pre>
  
  <p>and</p>
  
  <pre><code>$args = array(
      array('s' =&gt; 'Apple',),
      array('s' =&gt; 'Banana',),
      'cat'               =&gt; 80,
      'posts_per_page'    =&gt; -1,
      'orderby'           =&gt; date,
      'order'             =&gt; desc,
  );
  </code></pre>
  
  <p>Both return all posts from the given category even if there is only one element in the subarray, so it seems <code>'s'</code> couldn't be put in a subarray or contain array as the argument. Or I have mistyped somewhere but I can not catch where.</p>