You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@peterwilsoncc do you think it's noting the WP site URL ahead of the input field including a trailing / and then strip any leading / in the input field?
I'll do some further tests with the code @iamdharmesh left commented out in 4c04218 and see if there are further edge cases for regexes starting with ^ or ^/.
Describe the bug
Enabling a regular expression without a leading
/
can be quite buggy.Steps to Reproduce
Scenario One
(go|be)\/h{0,}$
/404-regex
curl -I http://xu-osp-plugins.local/be/hhhh
http://xu-osp-plugins.local/wp-admin/
Scenario Two
(go|be)\/h{0,}$
http://xu-osp-plugins.local/404-regex
curl -I http://xu-osp-plugins.local/be/hhhh
/http://xu-osp-plugins.local/wp-admin/
(note leading slash)Screenshots, screen recording, code snippet
No response
Environment information
WordPress information
WordPress 6.0
WordPress 5.9
WordPress 5.8
Code of Conduct
The text was updated successfully, but these errors were encountered: