Decode a UTF-8 string to ISO-8859-1:
<?php
$text = "\xE0";
echo utf8_encode($text) ."<br>";
echo utf8_decode($text);
?>
Try it Yourself »
The utf8_decode() function decodes a UTF-8 string to ISO-8859-1.
This function decodes a string, previously encoded with the utf8_encode() function, back to ISO-8859-1.
utf8_decode(string)
Parameter | Description |
---|---|
string | Required. Specifies a UTF-8 encoded string to decode |
Return Value: | The decoded string on success. FALSE on failure |
---|---|
PHP Version: | 4.0+ |
截取页面反馈部分,让我们更快修复内容!也可以直接跳过填写反馈内容!