jq的get传参数在utf-8中乱码问题的解决php版

Vicky ·
更新时间:2024-09-20
· 929 次阅读

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<script>
document.write(escape("哈哈")+"<br>");
document.write(unescape("%u54C8%u54C8")+"<br>");
document.write(encodeURIComponent("哈哈")+"<br>");
document.write(decodeURIComponent("%E5%93%88%E5%93%88")+"<br>");
</script>
</head>
<body>
<?php
echo urldecode("%E5%93%88%E5%93%88");
echo "<br>";
echo rawurldecode("%E5%93%88%E5%93%88");
echo "<br />";
echo utf8_decode("%E5%93%88%E5%93%88");
echo "<br />";
echo "%E5%93%88%E5%93%88";
echo "<br />";
echo $_GET['act'];
echo "<br />";
echo urlencode($_GET['act']);
?>
</body>
</html> 您可能感兴趣的文章:PHP iconv 解决utf-8和gb2312编码转换问题PHP乱码问题,UTF-8乱码常见问题小结php中utf-8编码下用正则表达式如何匹配汉字php中隐形字符65279(utf-8的BOM头)问题php中json_encode UTF-8中文乱码的更好解决方法php utf-8转unicode的函数PHP utf-8编码问题,utf8编码,数据库乱码,页面显示输出乱码php中文乱码怎么办如何让浏览器自动识别utf-8PHP 截取字符串函数整理(支持gb2312和utf-8)php UTF-8、Unicode和BOM问题PHP如何实现Unicode和Utf-8编码相互转换php smarty截取中文字符乱码问题?gb2312/utf-8PHP 与 UTF-8 的最佳实践详细介绍



get 乱码 参数 jq PHP

需要 登录 后方可回复, 如果你还没有账号请 注册新账号