@font-face Generator,子文件夹中的页面在 Firefox 中不起作用

发布于 2024-09-26 19:06:15 字数 390 浏览 1 评论 0原文

使用 Font Squirrel 的字体生成器时遇到奇怪的问题。我按照这些步骤操作,并使其在所有浏览器中都能正常工作。

然而,一旦我创建一个新文件夹并复制索引文件,并更改 CSS 根,新页面就无法工作,但原始页面就可以。这种情况仅发生在 Firefox 3.6 中,所有其他浏览器都能正确呈现新页面(即 /test/index.html)。

要重现此问题,请使用 http://www.fontsquirrel.com/fontface/generator,然后解压文件,创建一个新文件夹并将demo.html复制到新文件夹中并修改CSS路径。

这是一个常见问题吗?

Having a weird issue using Font Squirrel's font generator. I follwed the steps and have it all working in all broswers.

However as soon as I make a new folder and copy across the index file, and alter the CSS root, the new page does not work, but the original does. This is only happening in Firefox 3.6, all other browsers render the new page correctly (i.e. /test/index.html).

To replicate the issue, generate a font using http://www.fontsquirrel.com/fontface/generator, and then unzip the files, create a new folder and copy across the demo.html to the new folder and amend the CSS path.

Is this a common issue?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

懒猫 2024-10-03 19:06:15

我也可以复制这个错误。我将此归因于 Firefox 的 bug。

I can replicate the bug as well. I chalk this up to a Firefox bug.

霊感 2024-10-03 19:06:15

好的,感谢 法国论坛帖子 我今天早上关注了。

这只是由于 security.fileuri.strict_origin_policy Firefox 的参数。文档说:

正确:本地文档可以访问同一目录和子目录中的其他本地文档,但不能访问目录列表。 (默认)

False:本地文档可以访问所有其他本地文档,包括目录列表。

推荐设置:如果您使用本地文件进行开发并且需要能够检索其他本地文件,则可能需要将此首选项设置为 false。否则,将其设置为 true 可以提供最高的安全性。

为了在您的环境中解决此问题:

Ok i got the answer thanks to a french forum post i folowed this morning.

This is only a LOCAL issue due to the security.fileuri.strict_origin_policy param of Firefox. The documentation says that :

True : Local documents have access to other local documents in the same directory and in subdirectories, but not directory listings. (Default)

False : Local documents have access to all other local documents, including directory listings.

Recommended settings : If you do development with local files and need to be able to retrieve other local files, you may need to set this preference to false. Otherwise, leaving it set to true offers the most security.

In order to fix that on your environment :

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文