最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

wp redirect - Overiding wp_sanitize_redirect for | character

programmeradmin4浏览0评论

I am not really conversant with php and I have an issue with wp_sanitize_redirect. I have seen this excellent question and answer:

wp_sanitize_redirect strips out @ signs (even from parameters) -- why?

How do I override this method Wordpress so that I can pass the | as part of a URL and it not get stripped out?

I am using the latest 5.x edition of Wordpress.

I am not really conversant with php and I have an issue with wp_sanitize_redirect. I have seen this excellent question and answer:

wp_sanitize_redirect strips out @ signs (even from parameters) -- why?

How do I override this method Wordpress so that I can pass the | as part of a URL and it not get stripped out?

I am using the latest 5.x edition of Wordpress.

Share Improve this question edited Dec 8, 2019 at 20:17 Andrew Truckle asked Apr 16, 2019 at 7:36 Andrew TruckleAndrew Truckle 1077 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

There was another solution. I looked here:

https://www.w3schools/tags/ref_urlencode.asp

And it stated the encoded value for a | character was %7C so I was able to use that in my redirection URLs.

发布评论

评论列表(0)

  1. 暂无评论