I read the thread about adding a filter on the last line of the code, but am not sure that will work here.


In the middle right column in the Promotions section, the 'Continue reading ->' link is linked to the wrong page.

How can I correct this?

<div id="globalcontent">
  $featuredPosts = new WP_Query();
  while ($featuredPosts->have_posts()) : $featuredPosts->the_post(); ?>
    <h2 style="color:#FFFFFF; background:url(http://ahy4life.com/images/right_top_header.jpg) no-repeat left top;"><center><?php the_title(); ?></center></h2>
      <style type="text/css">
      div a{

      <?php the_excerpt(); ?>

      <?php endwhile; ?>
<div><img src="images/right_top_footer.jpg" alt="" /></div>
<div style="background-color: #FFF;"></div> 


  • If you mean "middle of the right column on the Promotions page", that section is talking about events and the link is to the events page. What is the problem? – s_ha_dum Dec 12 '12 at 15:52
  • @user24732 Both box's ("events" and "promotion") continue reading link pointing to same events.php. Is it what you are trying to fix? – M-R Dec 12 '12 at 16:01

Use "wp_reset_postdata();" right after "endwhile;" seems like your second query fetching link from your previous query.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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