StudioPress Community Forums
  StudioPress Community Forums > Forums > General Discussion
For help and support, access to your downloads, or to manage your account please log into My StudioPress.

These forums have been set to read-only so you can browse the existing topics for any questions you may have.

For general discussion on WordPress, CSS and design (NOT for support) visit the new Community Forums.
 
 
Thread Tools Display Modes
  #1  
Old 10-22-2012, 10:15 AM
Collins Collins is offline
Registered User
Genesis Member
 
Join Date: Jan 2012
Posts: 58
Default Removing 'Next Page' link from last page of blog

Any idea on how to get rid of the 'Next Page' link on the last listings page: http://bit.ly/Rpj9G4? Since there are no more blog posts beyond that page, it takes you to a 404.
  #2  
Old 10-22-2012, 10:58 AM
NicktheGeek's Avatar
NicktheGeek NicktheGeek is offline
Forum Manager
 
Join Date: Feb 2010
Posts: 62,650
Default

What is your posts per page setting in your reading settings? Are you changing the category or anything else for this?
__________________
Nick "Fred and/or George Weasley" Croft
Designs by Nick the Geek
@Nick_theGeek on Twitter

Make web design easier, get FireBug for FireFox

Want to learn more about Genesis? Check out my Genesis Explained Series

  #3  
Old 10-22-2012, 11:06 AM
Collins Collins is offline
Registered User
Genesis Member
 
Join Date: Jan 2012
Posts: 58
Default

"Blog pages show at most" is set to 30. I wonder if this has anything to do with it being used for Press Releases.
  #4  
Old 10-22-2012, 11:11 AM
NicktheGeek's Avatar
NicktheGeek NicktheGeek is offline
Forum Manager
 
Join Date: Feb 2010
Posts: 62,650
Default

the problem is you have it set to show 30 posts per page but in that template it is only showing 10 posts per page.
__________________
Nick "Fred and/or George Weasley" Croft
Designs by Nick the Geek
@Nick_theGeek on Twitter

Make web design easier, get FireBug for FireFox

Want to learn more about Genesis? Check out my Genesis Explained Series

  #5  
Old 10-22-2012, 11:23 AM
Collins Collins is offline
Registered User
Genesis Member
 
Join Date: Jan 2012
Posts: 58
Default

As a test, in our development environment, I reduced it to 5 posts per page, but it didn't affect either the Blog page or the Press Releases page. Both still show 10 posts per page.
  #6  
Old 10-22-2012, 12:18 PM
NicktheGeek's Avatar
NicktheGeek NicktheGeek is offline
Forum Manager
 
Join Date: Feb 2010
Posts: 62,650
Default

You appear to be using some kind of template file to change the query. It is using the grid loop output.
__________________
Nick "Fred and/or George Weasley" Croft
Designs by Nick the Geek
@Nick_theGeek on Twitter

Make web design easier, get FireBug for FireFox

Want to learn more about Genesis? Check out my Genesis Explained Series

  #7  
Old 10-22-2012, 12:29 PM
Collins Collins is offline
Registered User
Genesis Member
 
Join Date: Jan 2012
Posts: 58
Default

I think you're right. I wonder if the Press Releases template is count Blog posts.
  #8  
Old 10-22-2012, 12:38 PM
Collins Collins is offline
Registered User
Genesis Member
 
Join Date: Jan 2012
Posts: 58
Default

Strange. I found the control in a custom template, which had posts_per_page set to 10. No matter what number I change that to, I get a 404 for page 6. Just for testing purposes, I changed it to 100 and didn't get the Next Page link on page 2, which is correct (but we need to have it at 10 per page).

Here's the template:

PHP Code:
<?php
remove_action
'genesis_loop''genesis_do_loop' );
add_action'genesis_loop''pnap_grid_loop_helper' );
/** Add support for Genesis Grid Loop **/
function pnap_grid_loop_helper() {
    if ( 
function_exists'genesis_grid_loop' ) ) {
        
genesis_grid_loop( array(
            
'features' => 1,
            
'loop' => 'custom',
            
//'feature_image_size' => 'grid-ftd-thumbnail',
            //'feature_image_class' => 'alignleft post-image',
            
'feature_content_limit' => 500,
            
//'grid_image_size' => 'grid-thumbnail',
            //'grid_image_class' => 'alignleft post-image',
            
'grid_content_limit' => 500,
            
'more' => __'Read More''genesis' ),
            
'posts_per_page' => 10,
            
'post_type' => 'pnap_press_release'
        
) );
    } else {
    
        
genesis_standard_loop();
    }
}
 
/** Remove the post meta function for front page only **/
remove_action'genesis_after_post_content''genesis_post_meta' );
 
genesis();
  #9  
Old 10-22-2012, 01:12 PM
Collins Collins is offline
Registered User
Genesis Member
 
Join Date: Jan 2012
Posts: 58
Default

There are around 130 press releases. When I change the posts_per_page to 30, I don't get the Next Page link on the last page (page 5), which is correct. However, that doesn't resolve the issue, since that is too many per page. Any idea where to look?
  #10  
Old 10-22-2012, 03:33 PM
NicktheGeek's Avatar
NicktheGeek NicktheGeek is offline
Forum Manager
 
Join Date: Feb 2010
Posts: 62,650
Default

you will need to use a function in the functions.php file to customize the posts_per_page in the query
http://billerickson.net/customize-the-wordpress-query/
__________________
Nick "Fred and/or George Weasley" Croft
Designs by Nick the Geek
@Nick_theGeek on Twitter

Make web design easier, get FireBug for FireFox

Want to learn more about Genesis? Check out my Genesis Explained Series

 

Tags
blog, next page

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Removing Link from Parent Page joshguss General Discussion 2 02-15-2010 04:55 PM


All times are GMT -5. The time now is 12:37 PM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.