- August 29, 2016 at 2:33 pm #68932
I have no idea how my pagination is not showing correctly on the homepage here: http://www.helenedrage.no/
I use a pagination plugin called: Easy WP Page Navigation
It works in the category page: http://www.helenedrage.no/category/blogg/ as you will see different page (the following page) when you click the second page button (at the bottom of the page).
I thought it was the plugin problems. But after I tried many pagination plugins the problem keeps going. Since I saw that the second page for the older post, navigated from the homepage, will lead to this link: http://www.helenedrage.no/page/2/ and display the same page as shown in the first page. This also happens in the next pages after pages. It keeps displaying the first page and never the correct page.
<?php /** * The main template file. * * This is the most generic template file in a WordPress theme * and one of the two required files for a theme (the other being style.css). * It is used to display a page when nothing more specific matches a query. * E.g., it puts together the home page when no home.php file exists. * Learn more: http://codex.wordpress.org/Template_Hierarchy * * @package unite */ get_header(); ?> <div id="primary" class="content-area col-xs-12 col-sm-12 col-md-12 col-lg-12 <?php echo of_get_option( 'site_layout' ); ?>"> <main id="main" class="site-main" role="main"> <ul id="content-wrapper col-xs-12 col-sm-12 col-md-12 col-lg-12" class="left" style="margin:20px 0 0 -40px"><!--Content Wrapper--> <?php $query = new WP_Query( 'cat=-311,-313,-314' ); ?><!-- exclude category: uncategorized and tjenester --> <?php if ( $query->have_posts() ) : while ( $query->have_posts() ) : $query->the_post(); get_template_part( 'content', get_post_format() );?> <?php endwhile; ?> <div class="nav-links col-md-12"> <?php echo easy_wp_pagenavigation(); ?> </div> <?php else : ?> <?php get_template_part( 'content', 'none' ); ?> <?php endif; ?> </ul><!--Content Wrapper end--> </main><!-- #main --> </div><!-- #primary --> <?php get_footer(); ?>
Could you please let me know what’s exactly gone wrong?
Would it be sort of bug as I updated my WP to the newest version?
~ A u d e e
August 31, 2016 at 1:44 pm #69156
- This topic was modified 2 years, 9 months ago by audeemirza.
I hope you are well today and thank you for your question.
I visited your shared site to troubleshoot the pagination issue and found it is working fine as shown in the attached screenshot.
The first screenshot displays your home page and second screenshot displays the page after clicking on the second number in the pagination.
The topic ‘Pagination is not working correctly on the Homepage’ is closed to new replies.