• Resolved donmamone

    (@donmamone)


    I have added page numbers to the bottom of my main blog page as I anticipate the number of entries getting much longer. It looks good however when the viewer clicks on Page 2 the most recent post appears there again with the older posts following it.

    my blog can be found at https://www.donmamonephotography.com/blog

    I am using the Chaotic Soul theme and it is definitely specific to this theme because it does not do this if I switch to another theme.

    Any advise would be much appreciated.

    D-
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    Index.php code is:

    <?php get_header(); ?>

    <div id=”content” class=”narrowcolumn”>

    <?php if (have_posts()) : ?>

    <!– First Post –>
    <?php $top_query = new WP_Query(‘showposts=1’); ?>
    <?php while($top_query->have_posts()) : $top_query->the_post(); $first_post = $post->ID; ?>

    <div class=”post top” id=”post-<?php the_ID(); ?>”>
    <h2 class=”first”>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”><?php the_title(); ?></h2>
    <span class=”postmetadata”>• <?php comments_popup_link(‘No Comments’, ‘1 Comment’, ‘% Comments’); ?> <?php edit_post_link(‘Edit’, ‘(‘, ‘)’); ?></span>

    <div class=”entry”>
    <?php the_content(“<span class=\”continue\”>” . __(‘Continue reading’,”) . ” ‘” . the_title(”, ”, false) . “‘</span>”); ?>
    </div>
    </div>

    <?php endwhile; ?>

    <!– Next few posts –>
    <?php while(have_posts()) : the_post(); if(!($first_post == $post->ID)) : ?>

    <div class=”post lastfive” id=”post-<?php the_ID(); ?>”>
    <h2>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”><?php the_title(); ?></h2>
    <span class=”postmetadata”>• <?php comments_popup_link(‘No Comments’, ‘1 Comment’, ‘% Comments’); ?> <?php edit_post_link(‘Edit’, ‘(‘, ‘)’); ?></span>

    <div class=”entry”>
    <?php the_content(); ?>
    </div>
    </div>

    <?php endif; endwhile; ?>

    <?php else : ?>

    <h2 class=”center”>Not Found</h2>
    <p class=”center”>Sorry, but you are looking for something that isn’t here.</p>
    <?php include (TEMPLATEPATH . “/searchform.php”); ?>

    <?php endif; ?>

    <?php if(function_exists(‘wp_page_numbers’)) { wp_page_numbers(); } ?>

    </div>

    <?php get_sidebar(); ?>

    <?php get_footer(); ?>

Viewing 9 replies - 1 through 9 (of 9 total)
  • Thread Starter donmamone

    (@donmamone)

    Bump?

    Have you seen the nice searchbox on the top of the page? Search for query_posts + navigation. There are a lot of threads about this.

    Thread Starter donmamone

    (@donmamone)

    Evita,

    thank you for your reply. I have searched the forums and it would appear that the solution is there and I have tried cutting a pasting code multiple times but none of it seems to work for my specific theme. Here is a post that describes close to my exact same challenge but I can not seem to fix the problem with my theme no matter what I try. My page shows the first post over again, and then the older posts.

    I appreciate any assistance you can provide

    Thread Starter donmamone

    (@donmamone)

    Bump…any specific ideas…PLEASE! I know that there are smarter people than me out there with regards to this stuff. I am a photographer not a coder ??

    Looks like you solved the problem. There’s a channel for Chaotic Soul theme that you might like to try out.

    Thread Starter donmamone

    (@donmamone)

    Nope. problem persists ?? The most recent post titled Andrew and Angela (The Sequel) persists both pages 1 and 2. Not sure why it duplicates only the first post on the second page but would REALLY appreciate any ideas. In the mean time I will be sure to reference and post on the Chaotic Soul theme thread

    Thanks!

    Thread Starter donmamone

    (@donmamone)

    Bump? PLEASE HELP

    @donmamone: If you have wp-cache or super cache, clear cache. Clear browser cookies as well because I do not see any duplication anymore in single post pages either in IE or FF. What browser are you using and what version?

    It seems you solved this without posting the solution, not recommended. Can you please say how you solved the issue so others can fix this to?

    I’ve been looking around and i found the author of the theme had replied to your thread on that support site, but not even he gave the instructions to fix it, cause apparently he saw you already fixed it.

    Really frustrating.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘First post appearing on multiple pages’ is closed to new replies.