css - ie8 忽略了我所有的字体声明

标签 css internet-explorer-8 font-face compass-sass

我已经用谷歌和 stackoverflow 搜索了几个小时,但仍然无法正常工作。 我的问题是 ie8 完全忽略了我的字体声明,当我转到网络选项卡时,它甚至不需要来自服务器的字体(我没有看到错误,但我也没有看到调用)。有人有想法吗? 我正在使用 compass :

@include font-face(
  fontello,
  font-files(
      "fontello.eot?98351649",
      "fontello.eot?98351649?iefix",
      "fontello.woff?98351649",
      "fontello.ttf?98351649",
      "fontello.svg?98351649#fontello"
  ),
  $weight:normal,
  $style:normal
);

编译为:

@font-face {
  font-family: fontello;
  src: url('/static/fonts/fontello.eot?98351649') format('embedded-opentype'), url('/static/fonts/fontello.eot?98351649?iefix') format('embedded-opentype'), url('/static/fonts/fontello.woff?98351649') format('woff'), url('/static/fonts/fontello.ttf?98351649') format('truetype'), url('/static/fonts/fontello.svg?98351649#fontello') format('svg');
  font-weight: normal;
  font-style: normal;
}

然后:

body {
  font-family: fontello, Arial, Helvetica, Verdana !important;
}

有什么想法吗?谢谢

最佳答案

Fontello 在 IE8 中存在一些已知问题(而 IE8 在自定义字体方面存在问题)。

在此处查看类似问题:https://github.com/fontello/fontello/issues/70并在此处检查可能的答案:http://css-tricks.com/forums/topic/ie8-and-fontello/

作为一名开发人员,我的建议是:要么放弃 IE8,要么放弃 Fontello 并选择使用图像/ Sprite 的经典方法。

关于css - ie8 忽略了我所有的字体声明,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19862134/

相关文章:

javascript - IE8 - JavaScript 下拉 onchange 调用 "role()"导致错误

html - 自定义字体无法在 Chrome 中正确加载

css - 从谷歌网络字体或从自己的服务器加载字体,哪一个在页面加载时间方面更有效?

html - Firefox 中不显示 Web 字体

html - 水平对齐父 div 中的 UL 元素,两边都没有空格?

c# - Office 365/Sharepoint网站开发

css - IE8 不加载背景图像和背景颜色 CSS

java - 如何解析/格式化充满 CSS 代码的 RSS 标签

javascript - 如何在使用 Javascript 更改后更改 CSS 占位符颜色

css - 如何在 Internet Explorer 8 中将图像填充到 100%?