[wp-trac] [WordPress Trac] #44587: Page variable is not compared to actual pages count on single post

WordPress Trac noreply at wordpress.org
Mon Jul 16 15:16:39 UTC 2018


#44587: Page variable is not compared to actual pages count on single post
-------------------------+-----------------------------
 Reporter:  ekatherine   |      Owner:  (none)
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Permalinks   |    Version:  4.9.7
 Severity:  normal       |   Keywords:
  Focuses:               |
-------------------------+-----------------------------
 Since there's no check if {{{page}}} value more than actual pages count
 (by this I mean the number of {{{'<!--nextpage-->'}}} occurs), it's
 possible to create a billion of links with the same content but with
 different {{{page}}} value. I even caught this bug on this blog:
 https://wordpress.org/news/2018/07/update-on-gutenberg/9999/

 I guess it's not good for SEO.

 I managed to fix this on my website (which is on the latest version 4.9.7)
 by editing the file wp/wp-includes/canonical.php, now it redirects user to
 the last available page (or removes page part from the address if there's
 only one page).

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/44587>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list