Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个向浏览器输出有效 XML 的 PHP 脚本。有没有办法让 Chrome 将其显示为 XML?
尝试更改 HTTP 标头中的内容类型以声明输出为 XML 格式。把它放在你的 PHP 脚本的顶部:
header('Content-type: text/xml');