Google 字体(上面有空格)无法在 IE7/IE8 上呈现

发布于 2024-12-01 04:34:55 字数 720 浏览 2 评论 0 原文

有谁知道为什么 IE7/IE8 不会渲染 Google 字体(如果名称上有空格)?

您可以在此处查看演示: http://jsfiddle.net/fYzAb/1/

完全相同两个标签,一个使用“Oswald”,另一个使用“Francois One”(回退到乔治亚州,以便更容易发现)。

您可以在此处查看屏幕截图http://screencast.com/t/dhhccz5n7O(IE),具体方法如下它应该呈现: http://screencast.com/t/9M9uhTYTw5n (Chrome)

任何帮助将不胜感激!

顺便说一句:这里有一个类似的问题,http://www.htmlcodetutorial。 com/comments/viewtopic.php?f=2&t=20841

PD:我知道我可以在同一个标​​签中调用两种字体。

Does anybody has an idea why would IE7/IE8 won't render a Google Font if the name has a space on it?

You can see a demo here: http://jsfiddle.net/fYzAb/1/

The exact same two tags, one using "Oswald" the other one using "Francois One" (with fallback to Georgia to make it easier to spot).

You can see a screenshot here http://screencast.com/t/dhhccz5n7O (IE) and here's how it should render: http://screencast.com/t/9M9uhTYTw5n (Chrome)

Any help would be greatly appreciated!

BTW: Here's a similar problem, http://www.htmlcodetutorial.com/comments/viewtopic.php?f=2&t=20841

PD: I know I can call both fonts in the same tag.

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

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

发布评论

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

评论(3

撩心不撩汉 2024-12-08 04:34:55

我想您也找到了这个:http://code.google。 com/p/googlefontdirectory/issues/detail?id=1
(今天有一篇关于 Francois One 的帖子,我猜是你的)

有一个适合我的解决方案(我现在在 IE6-9 中看到该字体)

字体在 IE 中无法加载的最常见原因是因为字体作者编码错误的字体名称表。约瑟芬的情况绝对如此。姓氏 + 风格名称必须 = 全名。约瑟芬失败了。
仅供参考 - fontsquirrel.com 会自动纠正其网络字体中的这些问题。

这一定是原因,原始字体中的一些错误命名对 IE 很重要

  1. google
  2. 已在 fontsquirrel.com 并获取了我的“@font-face-kit”
  3. 将创建的 .eot 上传到套件中
  4. 编辑了有关 这个防弹语法

我只将 EOT 的 URL 更改为我上传的字体,用于 WOFF我仍然可以使用 google-font(但我想最好为每种字体使用自己的文件,没有人知道通过当前 URL 可以访问特定字体多长时间)。

另请注意:CSS 中使用的 font-family-name 现已更改为 FrancoisOneRegular

http://jsfiddle.net/doktormolle/nLUgJ/

I guess you have also found this one: http://code.google.com/p/googlefontdirectory/issues/detail?id=1
(there was a post today regarding to Francois One, I guess it was yours)

There is a solution that works for me(I see the font now in IE6-9)

The most common reason fonts don't load in IE is because the font name table was coded wrong by the font author. That is definitely the case with Josefin. The Family Name + the Style Name must = The Full Name. Josephine fails this.
FYI - fontsquirrel.com automatically corrects these problems in their webfonts.

This must be the reason, some wrong naming inside the original font which matters to IE

  1. Downloaded the TTF from google
  2. Uploaded the font at fontsquirrel.com and got my "@font-face-kit"
  3. Uploaded the created .eot inside the Kit
  4. Edited the css regarding to this bulletproof syntax

I changed only the URLs of the EOTs to my uploaded font, for the WOFF I still may use the google-font(But i guess it's better to use own files for every font, nobody knows how long the specific fonts will be reachable via the current URLs).

Also Note: the font-family-name to use inside the CSS has changed now to FrancoisOneRegular

http://jsfiddle.net/doktormolle/nLUgJ/

又怨 2024-12-08 04:34:55

尝试将 + 符号替换为 %20。我用 %20 检查了 url,它也有效,也许它适用于 IE。

https://fonts.googleapis.com/css?family=Francois%20One

Try replace + sign to %20. I checked url with %20 and it works too, maybe it'll work for IE.

https://fonts.googleapis.com/css?family=Francois%20One
仅此而已 2024-12-08 04:34:55

我认为可能是字体本身检查这个

http://jsfiddle.net/gHury/1/

I think it may be the font itself check this

http://jsfiddle.net/gHury/1/

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