php decode javascript escape的函数,该怎么解决

WBOY
Release: 2016-06-13 13:39:17
Original
786 people have browsed it

php decode javascript escape的函数
function utf8_urldecode($str) {  
  if(strpos('+'.$str,'%u')>0)  
  {  
  $str = preg_replace("/%u([0-9a-f]{3,4})/i","\\1;",urldecode($str));  
  return html_entity_decode($str,null,'UTF-8');;  
  }elseif(strpos('+'.$str,'%'))  
  {  
  return urldecode($str);  
  }else  
  {  
  return $str;  
  }  
  
  }

------解决方案--------------------
你想问什么?
------解决方案--------------------
马克
------解决方案--------------------
lz是来发帖留念的,不是来发问的吧?

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!