警告:SimpleXMLElement :: asXML():输出转换因转换错误而失败,字节0xF8 0x72 0x72 0x65

时间:2014-02-19 11:01:32

标签: php xml simplexml

我收到了我在标题中写的错误。

生成错误的行说明了这个

$properties->asXML("$filename.xml");

尽管我使用此字符串来初始化对象

$properties = new SimpleXMLElement('<?xml version="1.0" encoding="UTF-8" standalone="yes"?><properties/>');

然后输出:

<?xml version="1.0" encoding="ISO-8859-1" standalone="yes"?>

为什么它会改变编码标签?

0 个答案:

没有答案