Php R%C3%A9f%C3%A9R的字符编码
对于此类文本,应使用哪种类型的字符编码:Php R%C3%A9f%C3%A9R的字符编码,php,Php,对于此类文本,应使用哪种类型的字符编码: R%C3%A9f%C3%A9rence 我使用了htmlentities和utf8_编码,但它不起作用我想我得到了你问题的答案。首先确保您的文档具有正确的字符集 header('Content-Type: text/html; charset=utf-8'); echo urldecode('R%C3%A9f%C3%A9rence'); 你试过rawurldecode()吗?看起来像是urlencoded。尝试urldecode()获取真实的字符…您
R%C3%A9f%C3%A9rence
我使用了htmlentities和utf8_编码,但它不起作用我想我得到了你问题的答案。首先确保您的文档具有正确的字符集
header('Content-Type: text/html; charset=utf-8');
echo urldecode('R%C3%A9f%C3%A9rence');
你试过rawurldecode()吗?看起来像是urlencoded。尝试urldecode()获取真实的字符…您真正想做什么?回声urldecode(“R%C3%A9f%C3%A9rence”);应将其转换回正常可读文本。@Code-Hunter-Code
echo-urldecode('R%C3%A9f%C3%A9rence')代码>打印Référence
…使用urldecode,我得到了这个Référence� � F� � 法国