More
    HomeDesign / DevDefine How Many Post to Display Per Page on WordPress

    Define How Many Post to Display Per Page on WordPress

    By default, the WordPress loops displays 10 posts per page. You can change this inside WordPress admin panel manually without any headache of coding. However, in some circumstances you may require to overwrite those setting. There is a way to overwrite them in case you forgot to do so, here’s the hack to define how many post to display per page on WordPress website.

     

    - Advertisement -

    Simply replace your current loop with code below:

    [sourcecode language=’php’]

    - Advertisement -

    // WordPress loop

    endwhile;endif; ?>[/sourcecode]

    This loop will show 7 posts per page and enables the paginator if available. Do you have other way to achieve the same result? Share with us if you have any!

    - Advertisement -
    WPTidBits
    WPTidBitshttps://wptidbits.com/
    Owner of WPTidBits. Totally in love with WordPress!

    LEAVE A REPLY

    Please enter your comment!
    Please enter your name here

    110FansLike
    761FollowersFollow