[wp-trac] [WordPress Trac] #39535: Canonical redirects disallow tag named comments
WordPress Trac
noreply at wordpress.org
Tue Jan 10 09:04:07 UTC 2017
#39535: Canonical redirects disallow tag named comments
--------------------------+-----------------------------
Reporter: dwc | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Canonical | Version: 4.7
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
The `redirect_canonical` function includes a regular expression
replacement which effectively disallows tags named "comments" to have an
RSS feed:
https://github.com/WordPress/WordPress/blob/master/wp-
includes/canonical.php#L285
For example:
/blog1/tag/comments/feed/
This is redirected to:
/blog1/tag/feed/
Could / should the regular expression on line 285 could pay attention to
the first placeholder it matched (`comments/?`) or check whether the page
is a tag request?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/39535>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list