Guest User

Untitled

a guest
May 17th, 2016
60
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2.  
  3.     $query = new WP_Query(
  4.         array(
  5.             'post_type' => array('project'),
  6.             'meta_query' => array(
  7.                 array( 'key' => 'my_meta_key', 'value' => 'query string', 'compare' => 'LIKE' )
  8.             )
  9.         )
  10.     );
  11.  
  12.     while ( $query->have_posts() ) :
  13.         $query->the_post();
  14.         echo get_the_title();
  15.         // ...
  16.     endwhile;
RAW Paste Data