Support » Fixing WordPress » wp query tags does not return anything

  • Resolved cogmios

    (@cogmios)


    this:

    $wp_query = new WP_Query();
    	$wp_query->set('tag', 'issue');
    	$wp_query->set('posts_per_page', 30);
    	$wp_query->set('offset', $paged*30);
    	$posts = $wp_query->get_posts();
    	if ($posts) : foreach ($posts as $post) : the_post();

    does not return anything.. hmmm ?

Viewing 1 replies (of 1 total)
  • cogmios

    (@cogmios)

    solved!

    Always the same lesson: turn off caching before testing… (see how I found it out: http://edward.de.leau.net/resolved-cant-display-specific-tags-in-wordpress-sidebar-20100411.html

    p.s. I’m still looking for a way to have independent paging of multiple Wp-Query results on a page.

    It will probably mean passing multiple query vars e.g. /page/31 would mean input for the main query loop and /page/31+but+with+specific+page+13+of+an+applet would then mean within that page page 13 of a specific applet.

    I wonder if someone made something like this already?

Viewing 1 replies (of 1 total)
  • The topic ‘wp query tags does not return anything’ is closed to new replies.