简体   繁体   English

PHP DomDocument使用HTML保存XML

[英]PHP DomDocument Save XML with HTML

如何保存用DomDocument打开的XML文件,以免将其中的HTML编码为HTML实体?

I'd say, read through it however you normally are going to, then use html-entity-decode() 我想说,但是您通常会读通它,然后使用html-entity-decode()

http://www.php.net/manual/en/function.html-entity-decode.php http://www.php.net/manual/zh/function.html-entity-decode.php

in whatever you are using to write it back out as xml. 无论您使用什么方式将其写回xml。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM