What is the equivalent of JavaScript's decodeURIcomponent in PHP?

ぃ、小莉子 提交于 2019-12-09 07:23:34

问题


I have a string with unicode characters that I am transferring via HTTP. This string was encoded with Javascript's encodeURIcomponent(). Is there an equivalent function in php to Javascript's decodeURIComponent()?


回答1:


urldecode()

However you do not need to use it on $_REQUEST variables, which are already decoded automatically.



来源:https://stackoverflow.com/questions/3896591/what-is-the-equivalent-of-javascripts-decodeuricomponent-in-php

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!