Quantcast
Channel: WordPress.org Forums » All Posts
Viewing all articles
Browse latest Browse all 134392

Harish Chouhan on "Pagination issue when Trackbacks & Comments are seperated"

$
0
0

Hello,

I have trackbacks and comments separate in my theme.

  • For testing as per WordPress Theme review, I have set comment pagination with only 5 comments being displayed on each page.
  • For a post on which I have 2 trackbacks and 18 comments, on the first page, the 2 trackbacks are shown and 3 comments are shown
  • On subsequent pages, no trackbacks are shown and 5 comments are shown on each page

Issue is:
From the 2nd paginated pages onward, no trackbacks are shown but the heading "Trackback" is still displayed.
I use this code to display the pings:

/* Display Pings -------------------------------------------------------------*/
            if ( ! empty($comments_by_type['pings']) ) : // if there are pings ?>

                   <h3 class="pings-title"><?php _e('Trackbacks for this post', 'dreamsonline') ?></h3>

                    <ol class="pinglist">
                        <?php wp_list_comments( 'type=pings&callback=dreamsonline_list_pings' ); ?>
                    </ol>

            <?php endif; // end pings

Is there a way, to make sure:

1. remove the trackback heading from the 2nd page onwards
2. Or keep trackback out of the pagination, so that on the main post page, 5 comments are shown and all the trackbacks?


Viewing all articles
Browse latest Browse all 134392

Trending Articles