php javascript url encoding

前端 未结 4 417
深忆病人
深忆病人 2020-12-24 12:49

I have a html text. I had encoded it in php using urlencode function. I want to decode that text in the javascript. when i use unescape function in javascript it replaces a

4条回答
  •  孤城傲影
    2020-12-24 13:18

    PHP rawUrlEncode() == JavaScript encodeURIComponent()

    PHP rawUrlDecode() == JavaScript decodeURIComponent()

提交回复
热议问题