Home › Forums › Support › Pagination for static blog page This topic has 3 replies, 2 voices, and was last updated 5 years, 10 months ago by Tom. Viewing 4 posts - 1 through 4 (of 4 total) Author Posts May 20, 2018 at 10:35 am #580198 Philipp Please take a look at http://www.ktf2018.ch. Here I use a static homepage page-home.php where I output the latest posts of a specific category which works so far. The issue I have: pagination (at the bottom of the page) is not working. So URL’s like http://www.ktf2018.ch/page/2/ or http://www.ktf2018.ch/page/3/ don’t work. Find my code here (screenshot) Can it be related to codex.wordpress.org/Pagination (scroll down to “Static Front Page”)? Thanks, Philipp May 20, 2018 at 9:48 pm #580455 TomLead Developer Lead Developer That could definitely be the issue. I also suggest using WP_Query instead of query_posts, as they show in that example. May 28, 2018 at 2:36 pm #586601 Philipp Thank you Tom, it worked for me: if ( get_query_var( 'paged' ) ) { $paged = get_query_var( 'paged' ); } elseif ( get_query_var( 'page' ) ) { $paged = get_query_var( 'page' ); } else { $paged = 1; } $the_query = new WP_Query('posts_per_page=12&paged=' . $paged); ?> <?php if ( $the_query->have_posts() ) : while ( $the_query->have_posts() ) : $the_query->the_post(); // run the loop ?> May 28, 2018 at 5:02 pm #586644 TomLead Developer Lead Developer You’re welcome! 🙂 Author Posts Viewing 4 posts - 1 through 4 (of 4 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In