[wp-trac] [WordPress Trac] #35175: Page parameter no longer works in wp_list_comments
WordPress Trac
noreply at wordpress.org
Mon Dec 21 03:03:39 UTC 2015
#35175: Page parameter no longer works in wp_list_comments
-------------------------------+------------------------------
Reporter: smerriman | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Comments | Version: 4.4
Severity: normal | Resolution:
Keywords: reporter-feedback | Focuses:
-------------------------------+------------------------------
Comment (by smerriman):
I just installed Twenty Fifteen with a fresh version of WP 4.4 (no
plugins), created a post, and added 5 top level comments. Under Settings -
Discussion I set it to break into 2 top level comments per page (last
displayed by default, older comments at top of page - though changing
those settings doesn't alter the result). You should just see comment 5 on
the post.
In comments.php I copied the wp_list_comments line and pasted a second
copy directly underneath with the page parameter:
{{{
wp_list_comments( array(
'style' => 'ol',
'short_ping' => true,
'avatar_size' => 56,
'page'=>2
) );
}}}
You should then see comment 5 duplicated on the post - whatever page
setting you choose.
`wp_list_comments` has:
{{{
// Pagination is already handled by `WP_Comment_Query`, so we tell Walker
not to bother.
}}}
and then some code which ignores the page parameter and sets the cpage
parameter directly from the query var, so it shouldn't be possible to get
any other result.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/35175#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list