Change Post Numbers in Eleven40

Community Forums Forums General Discussion Change Post Numbers in Eleven40

This topic is: not resolved

Tagged: 

This topic contains 6 replies, has 3 voices, and was last updated by  braddalton 8 months, 1 week ago.

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #49297

    JWsimpkins
    Participant
    Post count: 13

    Hey guys,

    I’m currently using the Eleven40 theme and I’m trying to figure out how to change the number of posts that display on my homepage.

    Thanks!

    Jason

    http://fitmenover40.com
    #49299

    braddalton
    Participant
    Post count: 7454

    I think you can simply change the value for features in your home.php file:

    'features' => 1,
    

    WordPress Developer & Consultant
    Brad Dalton400+ StudioPress Tutorials & 1200+ Code snippets

    #49313

    JWsimpkins
    Participant
    Post count: 13

    Great, thanks Brad!

    #55844

    winnydejong
    Participant
    Post count: 26

    Hi Brad Dalton,

    I also have the Eleven40 theme. I’d like to change the homepage into 1 featured posts and 4 older ‘teaser’ post with the featured image. Any ideas how to do this?

    If I change the number of the featured posts in home.php, I’ll get more featured posts (full width) but I can’t seem to change the number of featured posts…

    Thanks in advance! Best, Winny

    #55848

    braddalton
    Participant
    Post count: 7454

    You mean 1 featured and 4 grid?

    You can do this with the new Eleven40 Pro version.

    This is how i did it.

    Go to Genesis > Theme Settings > Blog Page Template > Number of Posts to Show: 5

    Then go to Settings > Reading > Blog pages show at most: 5

    This is the default Eleven40 Pro version home.php file settings:

    <?php
    
    remove_action( 'genesis_loop', 'genesis_do_loop' );
    add_action( 'genesis_loop', 'eleven40_grid_loop_helper' );
    /** Add support for Genesis Grid Loop */
    function eleven40_grid_loop_helper() {
    
    	if ( function_exists( 'genesis_grid_loop' ) ) {
    		genesis_grid_loop( array(
    			'features'			=> 1,
    			'feature_image_size'	=> 0,
    			'feature_image_class' 	=> 'alignleft post-image',
    			'feature_content_limit' => 0,
    			'grid_image_size'		=> 'grid-featured',
    			'grid_image_class'		=> 'grid-featured',
    			'grid_content_limit' 	=> 250,
    			'more'				=> __( '[Continue reading]', 'eleven40' ),
    		) );
    	} else {
    		genesis_standard_loop();
    	}
    
    }
    
    genesis();
    

    The result

    index


    WordPress Developer & Consultant
    Brad Dalton400+ StudioPress Tutorials & 1200+ Code snippets

    #55851

    winnydejong
    Participant
    Post count: 26

    Sorry, I might have been unclear. I’d like the homepage to show only five posts (1 featured, 4 grid) but I want all the other pages – archive, categories etc. – to show 10.

    If I make the changes you describe those pages will only show 5 posts… Any ideas how to fix this?

    #55855

    braddalton
    Participant
    Post count: 7454

    I left the Reading Settings at 5 and changed the Genesis Blog Page Template settings to 15 and it showed 15 on the blog page and 5 on the home page.

    However, the archives will only show 5 so you would need to modify the custom grid loop.

    Or use this plugin http://wordpress.org/plugins/genesis-grid-loop/


    WordPress Developer & Consultant
    Brad Dalton400+ StudioPress Tutorials & 1200+ Code snippets

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.