Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter mookierah

    (@mookierah)

    Actually, I think I fixed the problem. I didn’t edit away all the old code and it was causing problems.

    Thread Starter mookierah

    (@mookierah)

    That’s definitely a step in the right direction, although I still get a glitch. Here is the current version of the code:

    <ul>
    <?php if(have_posts()) : ?>
    <?php if (is_page('art')) global $post; $myposts = get_posts('numberposts=5&offset=1&category=7');?>
    <?php foreach($myposts as $post) :?>
    <h5><li><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></li></h5>
    <?php endforeach; ?>
    </ul>
    <?php endif; ?>

    The problem with this is that it correctly displays the previous 5 entries in a list, but at the end it will display several of the current post as well. Not sure what is causing that.

Viewing 2 replies - 1 through 2 (of 2 total)