php encodeURI twice to solve the bug that the page cannot be found due to garbled error on the page of the browsing post jump request

The get submission parameter contains Chinese. If it is PHP, the front-end needs to encodeURI twice, because once encodeURI and some characters will not be encoded

 

 1  onclick="showRecord(this)" href="{:U('OilAnalysis/monitorRecord',array('mid'=>$vo['oid'],'bname'=>$vo['bname'],'sname'=>$vo['sname'],'uname'=>$vo['uname'],'oname'=>$vo['oname']))}" 
 2 var showRecord=function(e){
 3     var hf=$(e).attr('href');
 4     var url=encodeURI(encodeURI(hf));
 5     // url=hf;
 6     location.href=url;
['mid']=$data10backend php
98}
7  
  urldecode(urldecode(I('mid')));
11 $data['bname']=urldecode(urldecode(I('bname')));

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324878574&siteId=291194637