是否可以在 Icecast XSL 文件中 add/set headers ?
Is it possible to add/set headers in Icecast XSL files?
我有一个 json.xsl 文件需要 Access-Control-Allow-Origin header。
我尝试通过添加
来实现此功能
<http-headers>
<header name="Access-Control-Allow-Origin" value="*" />
</http-headers>
到 "json.xsl" 文件的顶部,希望您不必全局设置它,但尽管它仍然可以正确解析,但它不会添加 header.
这是不可能的,还是我使用了错误的标签(或将标签放在了错误的位置?)
使用Icecast 2.4.2,它允许您任意配置headers。全局和每个 "mount"。您可以为要应用的 XSLT 文件定义 "mount",例如headers 或认证。
Icecast >2.4.1 也有工作 JSON API。 (2.4.0有问题,不建议使用!)
https://wiki.xiph.org/Icecast_Server/Installing_latest_version_(official_Xiph_repositories)
我有一个 json.xsl 文件需要 Access-Control-Allow-Origin header。
我尝试通过添加
来实现此功能<http-headers>
<header name="Access-Control-Allow-Origin" value="*" />
</http-headers>
到 "json.xsl" 文件的顶部,希望您不必全局设置它,但尽管它仍然可以正确解析,但它不会添加 header.
这是不可能的,还是我使用了错误的标签(或将标签放在了错误的位置?)
使用Icecast 2.4.2,它允许您任意配置headers。全局和每个 "mount"。您可以为要应用的 XSLT 文件定义 "mount",例如headers 或认证。
Icecast >2.4.1 也有工作 JSON API。 (2.4.0有问题,不建议使用!)
https://wiki.xiph.org/Icecast_Server/Installing_latest_version_(official_Xiph_repositories)