WordPress.org

Ready to get started?Download WordPress

Forums

pagination custom post type (3 posts)

  1. funkycamel
    Member
    Posted 2 years ago #

    If anyone can help I'll be thrilled ! ! ! !

    My pagination is working fine for my custom post type when the permalink settings is set to default. Correct number of posts are displayed on the page and when you click page 2 it goes to page 2. The problem is when I change my permalink settings in the admin to post name ( /%postname%/ ) it stops working. The pagination still shows up at the bottom of the page and it still shows the correct number of pages but when I click page 2 it only displays the footer page code on the screen. I've tried everything but no joy.

    Below is the url in question, scroll down and click page 2 and you will see.

    http://www.jamiepotepa.co.uk/ternquay2/listings/

  2. Rev. Voodoo
    Volunteer Moderator
    Posted 2 years ago #

    are you using any custom template for it? Especially one with a custom query?

  3. funkycamel
    Member
    Posted 2 years ago #

    this is my custom query

    $args = array( 'post_type' => 'listings', 'posts_per_page' => 5, 'beds' => $bedQuery, 'paged'=> $paged, 'post_status'=> 'publish' );
    $loop = new WP_Query( $args );
    while ( $loop->have_posts() ) : $loop->the_post();

    I'm using a custom template page called template-listings if thats what you meant?

Topic Closed

This topic has been closed to new replies.

About this Topic