Support » Plugin: Featured Post » Featured posts only showing in Front Page

  • Resolved farshid.t


    Hi and thanks for the great Plugin.

    I have added the query_posts function before the main loop and it does work when the page is set as Front Page in WP Reading Settings.

    However the query returns blank if the page is not Front Page, such as “/?page_id=11”.

    Is this a bug or do you suggest any way to trace back the error?

    Thanks a lot!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author WPPress


    can you paste your piece of code? so i can check what really is happening?

    Sure. But it turns out that there is conflict with my custom template. Nothing wrong on the plugin’s side.

    This is the relevant piece.

    <div class="container">		
    			<!-- FEATURED FILTERING -->
    			<?php query_posts($query_string."&posts_per_page=100&featured=yes"); ?>
    			<?php while (have_posts()) : the_post(); ?>
    	                     // show posts data, etc
    			<?php endwhile; ?>
    			<!-- /STOP LOOP -->
    			<?php wp_reset_query(); ?>


    Plugin Author WPPress


    did you try calling wp_reset_query() before query_posts() ?

    Plugin Author WPPress



    Sorry I couldn’t try during the weekend.

    wp_reset_query() doesn’t fix it, removing one of the template classes does. I guess a JS function is messing with it.

    I set my featured as front page, and it works fine there.

    Thanks anyway 🙂

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Featured posts only showing in Front Page’ is closed to new replies.