- This topic has 4 replies, 2 voices, and was last updated 10 years, 2 months ago by .
Viewing 5 posts - 1 through 5 (of 5 total)
Viewing 5 posts - 1 through 5 (of 5 total)
- You must be logged in to reply to this topic.
Home › Community Forums › Skope Theme Support › pagenation?
Any idea why my pagenation isn’t working properly? dadshops2. I get an error 404 when i try to go to the second page.
Any help appreciated.
Not sure why thats happening. It seems to work fine on the demo. Have you added any extra code, plugins, or anything that could affect this area? Do you have additional posts?
I do have additional posts and when I increase the number of posts on the home page the pagenation goes away as it should. I will check the plugins. I only have a social share, sitemap and linkwithin. I will see if any of those is interfering.
Deactivated the plugins and no change. I haven’t added any code. I changed some dimensions on the columns but nothing drastic. Is there an area that you set up pagination?
I’m still not sure why its happening exactly, but it appears to be an issue with the Genesis Loop code. If you look in your home.php file near the bottom you’ll see this –
// Remove standard loop
remove_action(‘genesis_loop’, ‘genesis_do_loop’);// Add custom loop
add_action(‘genesis_loop’, ‘skope_home_loop’);
function skope_home_loop() {
$paged = get_query_var(‘paged’) ? get_query_var(‘paged’) : 1;$include = genesis_get_option(‘skope_home_cat’);
$exclude = genesis_get_option(‘skope_home_cat_exclude’) ? explode(‘,’, str_replace(‘ ‘, ”, genesis_get_option(‘skope_home_cat_exclude’))) : ”;$cf = genesis_get_custom_field(‘query_args’);
$args = array(‘cat’ => $include, ‘category__not_in’ => $exclude, ‘showposts’ => genesis_get_option(‘blog_cat_num’), ‘paged’ => $paged);
$query_args = wp_parse_args($cf, $args);genesis_custom_loop( $query_args );
}
If you delete or comment out the above code then it should work fine. When you do this, you will have to change the number of posts to show in your Settings > Reading page like you were doing before since the Genesis Settings page won’t work (since the code above removes that functionality for the homepage).
The only way I could make this issue appear was to change my number of posts to less than what it was, but it seemed to work fine if I had it at 9 for some reason. The suggestion above should fix it though.