Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #49510


Ignore:
Timestamp:
02/25/2020 11:05:59 AM (4 years ago)
Author:
SergeyBiryukov
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #49510 – Description

    initial v1  
    331. Go to ''Settings > Permalinks'', search for the ''Category base'' and/or a ''Tag base'' with some [RegExp meta-characters](https://www.php.net/manual/en/regexp.reference.meta.php), for example:
    44
    5 [[Image(set-permalinks.png)]]
     5[[Image(permalinks.png)]]
    66
    772. Try to access a category archive page, either by typing its URL directly in your web browser, or by clicking on a generated link for this category:
     
    11113. Same for tag archive page:
    1212
    13 [[Image(category-base.png)]]
     13[[Image(tag-page.png)]]
    1414
    15 I've done some research, and it seems that a similar bug happen with feeds URL: https://core.trac.wordpress.org/ticket/43571
     15I've done some research, and it seems that a similar bug happen with feeds URL: #43571
    1616
    1717The proposed solution in the above patch is to escape the rewrite rules with PHP built in function `preg_quote()`, which would solve this problem too if we apply it in the correct location. But what is the correct location? And could other parts of the rewrite rules generation/evaluation benefits of escaping too?