WordPress.org

Ready to get started?Download WordPress

Forums

posts in the single.php (2 posts)

  1. marhoff
    Member
    Posted 8 years ago #

    Hello I'm new and I've problem with show posts on the curent post for exaplme I have code in single.php:
    (this is the post number f.e 'p=5')
    ....
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>

    /*now i'd like show on this post another post and i do .*/

    <?php if ($post->ID==5) : if(query_posts('p=7')): the_post(); the_content(); endif; endif;?>
    ....

    <?php endwhile; ?><?php endif; ?>
    ...
    /*and display me the post number 7 on post 5 - that's ok*/
    /*but i want display another post also on post 5 and the same code above don't display me another post contents - > why? */
    /*i've treid use "multiple loops" but don't work */
    /* how add another post contents in this post ? */

  2. justinholt
    Member
    Posted 8 years ago #

    Please dont double post.

Topic Closed

This topic has been closed to new replies.

About this Topic