Sunday, 19 May 2013

query posts in wordpress

query posts in wordpress

I want to filter my query results just before the_loop starts in word press. I only want the results having term_id or term_taxonomy_id equal to 1.
query_posts('post_type=my_post&term_id=1&posts_per_page=6');
This is returning all rows, I am new to word press so I am not sure that we can use term_id in query_posts. Is there any other way to do it?

No comments:

Post a Comment