[wp-trac] [WordPress Trac] #35419: Incorrect comment pagination when comment threading is turned off

WordPress Trac noreply at wordpress.org
Fri Jan 15 21:00:25 UTC 2016


#35419: Incorrect comment pagination when comment threading is turned off
--------------------------+---------------------------
 Reporter:  jmdodd        |       Owner:  boonebgorges
     Type:  defect (bug)  |      Status:  reopened
 Priority:  normal        |   Milestone:  4.4.2
Component:  Comments      |     Version:  4.4
 Severity:  normal        |  Resolution:
 Keywords:  fixed-major   |     Focuses:  template
--------------------------+---------------------------

Comment (by boonebgorges):

 Replying to [comment:9 navycs]:
 > You may be hitting the limits of my database query knowledge, but, yes,
 it appears close to what you are asking -- it seems that every one of my
 personal comments are a reply because each has a comment_parent number --
 a number like 135501 for example. But when I count each of my comments on
 a page and subtract them from the page's total count, it does not equal 75
 -- one page equaled 68 and another 81 -- now, there are a random few
 comments with the parent number that belong to others, but not a lot as
 compared to my own.

 Based on this, it sounds to me like my hypothesis is probably correct. The
 key question is not how many comments on a page *belong to you*, it's how
 many *have parents*. My guess is that the number of comments on a page,
 minus the number that have parents (whether authored by you or someone
 else) equals 75.

 If that's true, then [36275] should resolve your issue. I'm not sure how
 to explain the fact that it's not. The only way I'd be able to tell more
 is by doing some debugging on what query is taking place. I'm not sure how
 well-equipped you are to help with this sort of debugging. Specifically,
 I'd want to know the value of the `$comment_args` and
 `$top_level_comment_args` just before line 1334 here:
 https://core.trac.wordpress.org/browser/tags/4.4.1/src/wp-includes
 /comment-template.php?marks=1334#L1300 If you know how to provide that,
 it'd be great, but if you don't, I'm not going to tell you because I don't
 want to risk you crashing your site :)

 Side note - [36223] may be related.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35419#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list