Forums

[resolved] Tag page won't show all posts with that tag (3 posts)

  1. sr. varoa
    Member
    Posted 3 years ago #

    /tag/XXX only shows some posts tagged with XXX, I can see no relationship between all the posts that are missed, it seems totally random. I have tried saving them again, but no luck. I can't find anything related in the forum.

    The code of my /tag page is:

    <?php if (have_posts()) : ?>
    			<ul class='archive'>
    			<?php while (have_posts()) : the_post(); ?>
    				<li>
    					<a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title(); ?>"><?php the_title(); ?></a>
    					(<?php the_date(); ?>)
    				</li>
    				<?php the_post(); ?>
    			<?php endwhile; ?>
    			</ul>
    		</div>
  2. MichaelH
    Volunteer
    Posted 3 years ago #

    Replace

    <?php the_post(); ?>
    <?php endwhile; ?>

    with

    <?php the_content(); ?>
    <?php the_tags('Tags: ', ', ', '<br />'); ?>
    <?php endwhile; ?>

    And see what tags are being displayed.

  3. sr. varoa
    Member
    Posted 3 years ago #

    Ah damn, true, I was doing two the_post() inside the loop so it skipped one every two posts. Just removing that second the_post it shows the complete list.

    Thanks a lot.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags