• I’m trying to show latest post from a category


    <?php $my_query = new WP_Query('showposts=15&cat=6'); while ($my_query->have_posts()) : $my_query->the_post(); $do_not_duplicate = $post->ID; ?>
    SOME CODE
    <?php endwhile; ?>

    and to show after this a simple box inside a statement

    <?php if (is_home() && !is_paged()) {?><?php include (TEMPLATEPATH . '/box.php'); ?><?php } ?>

    Conditional Tag is not respected from WordPress showing the box in every page. WordPress must show the box only on home page (index.php).

    Do you have solutions ?

    Best Regards

Viewing 1 replies (of 1 total)
  • Thread Starter isw79

    (@isw79)

    A little update, this code is on sidebar and not inside index.php or whatsoever.

Viewing 1 replies (of 1 total)
  • The topic ‘Conditional Tags and WP_Query – WordPress Buggy ?’ is closed to new replies.