[wp-trac] [WordPress Trac] #35562: Single post pagination redirect back to page one with nextpage tag - WordPress 4.4.1

WordPress Trac noreply at wordpress.org
Fri Jan 22 11:06:19 UTC 2016


#35562: Single post pagination redirect back to page one with nextpage tag -
WordPress 4.4.1
--------------------------+-----------------------------
 Reporter:  pietergoosen  |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Future Release
Component:  Canonical     |     Version:  4.4
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |     Focuses:
--------------------------+-----------------------------

Comment (by birgire):

 The problem is that {{{WP::handle_404()}}} is executed long before
 {{{setup_postdata()}}} where the {{{content_pagination}}} filter currently
 lives.

 I don't think we want to remove a restriction in {{{WP::handle_404()}}}
 that makes sure the current page number doesn't exceed the maximum number
 of content pages.

 If we want to keep it, I suggest we try to move the content pagination
 logic (including the {{{content_pagination}}} filter) from the
 {{{setup_postdata()}}} up to the {{{WP::handle_404()}}} method.

 The current content pagination isn't supposed to work for secondary loops
 anyways, as far as I understand it, even though the
 {{{content_pagination}}} filter is available to all loops through
 {{{setup_postdata()}}}.

 To support such a restriction for secondary loops, I think the
 corresponding post ID would need to be part of the GET request.


 ... or do you see any other way  ?

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


More information about the wp-trac mailing list