WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How to query posts from single post format on Genesis framework? I want to just show posts from gallery post format only.

I tried this query:

$recent = new WP_Query(
while($recent->have_posts()) : 

But I didn’t get what I wanted.

share|improve this question
Isn't there a Genesis support forum? – Chris_O Jun 30 '12 at 20:22
no replies there :( – iniyan Jul 1 '12 at 2:14
up vote 0 down vote accepted

The taxonomy should be post_format and term should be post-format-link. Also simple taxonomy queries are deprecated since 3.1 in favor of tax_query:

$args = array(
    'posts_per_page' => 5,
    'tax_query' => array(
            'taxonomy' => 'post_format',
            'field' => 'slug',
            'terms' => 'post-format-link'
$recent = new WP_Query( $args ); 
share|improve this answer
I did that. mistyped here :( – iniyan Jul 1 '12 at 2:13
your query is still wrong, use the code I've posted here. old query string style taxonomy arguments are taxonomy and term (not plural), and slug is not a valid argument. you should be using tax_query instead anyway. – Milo Jul 1 '12 at 2:27
Thanks. I fixed with your help – iniyan Jul 1 '12 at 16:52

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.