• Hi,

    I have a blog running with the latest version of WordPress and if you click on any of the “Read More” it always takes you to the latest post, even though $p is being passed across correctly (Which seems to represent the post ID)

    Any ideas?

    I have double checked and the output in single.php is still inside the while loop:

    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>

    Any ideas?

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

    (@udjamaflip)

    Well I’ve found the problem causing this error (which was occuring inside the archive list as well)

    <div class="left-nav">
        	<h2>Other posts</h2>
    		<?php
    
    		    $posts=get_posts('numberposts=5');
    
    			foreach ($posts as $post) :
    				?>
                    <?PHP the_time("d.m.y"); ?><a href="<?PHP the_permalink(); ?>"><?PHP the_title();  ?></a>
                <?PHP	endforeach; ?>
        </div>

    This was made to display 5 posts.

    Is there an easier way I should know of?

Viewing 1 replies (of 1 total)
  • The topic ‘Blog feed links to same post everytime (single.php)’ is closed to new replies.