XSLT stylesheet isn't applied to XML in Firefox. How to fix it?

rad*_*zek 6 xml xslt firefox xslt-1.0

I have no idea why my code isn't cooperating, with me and my xml. I'm sorry for giving pics, but when i'm giving code, site is displaying end result, not the code it self, and I have no idea how to change it.

<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet href="movies.xsl" type="text/xsl" ?>
<collection>
    <movie>
        <title>hasdasd</title>
        <year>1222</year>
        <genre>horror</genre>
    </movie>
    <movie>
        <title>wqw</title>
        <year>1111</year>
        <genre>notporn</genre>
    </movie>
    <movie>
        <title>asdsd</title>
        <year>1444</year>
        <genre>comedy</genre>
    </movie>
</collection>

Run Code Online (Sandbox Code Playgroud)

my XML code

<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:template match="/collection">
      <html>
        <body> <h1>OEIHFWOEFIHEFOI</h1>
        <table border="1">
            <tr>
                <th>title</th>
                <th>Genre</th>
                <th>year</th>
            </tr>
            <xsl:for-each select="movie">
            <tr>
                <td><xsl:value-of select="title" /></td>
                <td><xsl:value-of select="year" /></td>
                <td><xsl:value-of select="genre" /></td>
            </tr>
            </xsl:for-each>
        </table>
        </body>
      </html>
  </xsl:template>
</xsl:stylesheet>
Run Code Online (Sandbox Code Playgroud)

我的 XSLT 代码我真的不知道出了什么问题,似乎它们以错误的方式相互连接,但我仍然一无所知。

最终结果

evi*_*pie 4

首先:我强烈建议您使用本地 http 服务器,而不是修改 Firefox 中任何会降低安全性的首选项。

由于 Firefox 68 左右将本地文件视为始终跨域。(请参阅“本地 HTML 文件可能导致文件窃取”)这可以防止各种安全和隐私问题,例如攻击窃取与下载的 HTML 文件相同的文件夹中的本地数据。另请参阅文章“文件 URL 的限制”

更改security.fileuri.strict_origin_policy极其不安全的,不应该进行,因为它允许访问您计算机上的所有文件

编辑:我之前建议使用privacy.file_unique_origin,这不太不安全,但该偏好大约在两年前被删除,并且现在不起作用