Home >Backend Development >PHP Tutorial >php URL编码解码函数

php URL编码解码函数

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-05-19 14:05:241756browse

$url =”http://www.2881.com“;
echo urlencode($url);              //输出编码后的字符串
?>

$url = “http://www.2881.com“;
$newurl = urlencode($url);              //首先对$url进行编码
echo urldecode($newurl);               //输出解码后的字符串
?>

Statement:
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
Previous article:PHP图形验证码程序Next article:PHP守护Linux/Unix进程