[wp-trac] [WordPress Trac] #2877: A Slash too much @ get_pagenum_link()
WordPress Trac
noreply at wordpress.org
Mon Oct 16 00:05:44 UTC 2023
#2877: A Slash too much @ get_pagenum_link()
-------------------------------------------------+-------------------------
Reporter: dave@… | Owner: costdev
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 6.4
Component: Posts, Post Types | Version: 2.0
Severity: normal | Resolution: fixed
Keywords: has-patch has-unit-tests has- | Focuses: template
testing-info commit |
-------------------------------------------------+-------------------------
Changes (by costdev):
* status: reviewing => closed
* resolution: => fixed
Comment:
In [changeset:"56939" 56939]:
{{{
#!CommitTicketReference repository="" revision="56939"
Posts, Post Types: Don't force trailing slash in `get_pagenum_link()`.
Previously, a trailing slash was appended to the link returned from
`get_pagenum_link()`. If the permalink structure didn't contain a trailing
slash, this link could fail.
This change removes trailing slashes and only appends one if the site is
set for adding trailing slashes.
This adds a new test file for the accompanying tests,
`tests/phpunit/tests/link/getPagenumLink.php`, and moves an existing test
for `get_pagenum_link()` to the same file.
Props davemad-davenet, darkfate, Nazgul, scribu, nacin, obenland,
chriscct7, jesin, matthewppelsheimer, audrasjb, petitphp, mukesh27,
oglekler, mai21, webtechpooja, tejwanihemant, nicolefurlan,
hellofromTonya, costdev.
Fixes #2877.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/2877#comment:42>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list