wp_query issue
-
Hi,
Thanks for your help with this plugin. I am really confused. I am building a custom query, but i am not able to filter by event owner.
Here is the code i am working with:
<?php
$loop = new WP_Query( array( ‘post_type’ => ‘event’, ‘meta_key’ => ‘event_owner’, ‘meta_value’ => 1, ‘posts_per_page’ => 10 ) );
?><?php
while ( $loop->have_posts() ) : $loop->the_post();
?>FYI – If i omit meta_key’ => ‘event_owner’, ‘meta_value’ => 1 the loop works just fine. Any idea why that is?
Many thanks,
Yvan
- The topic ‘wp_query issue’ is closed to new replies.