html - ie8 在第一页加载或刷新时不呈现@font-face 字体

标签 html css internet-explorer-8

这是有问题的网站:https://www.cocokeyorlando.com

当我第一次访问该页面时,IE8 没有呈现我的自定义字体。应该为 slider 文本加载两种字体。如果我重新加载/刷新页面,则没有任何变化。

但是,当我单击 Logo 返回主页时,它们开始工作。

这是我用来加载它们的代码。

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

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

非常感谢任何帮助!

最佳答案

确保你的 fonts/black_jack.eot 文件在那里,并且 CSS 都是正确的。

站点在 IE11 或 IE8 模式下呈现效果不佳。该网站在 Chrome 中运行良好。

看看这些... Font Face not working in IE8 as expected

关于html - ie8 在第一页加载或刷新时不呈现@font-face 字体,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21123067/

相关文章:

html - 如何避免ie8兼容按钮?

html - Css 分页符在 IE 中的表格后导致额外的分页符

html - 如何进行 2 个链式变换,第一个有过渡,后面没有过渡?

JavaScript IE 使用 form.submit() 双重提交

ipad - 使用 HTTPS 在 iPad Safari 上播放 HTML5 视频

javascript - 保持图像和文本彼此相邻

javascript - 默认情况下显示选中的复选框

javascript - 以鼠标移动的度数计算 Angular

jquery - 是否可以使用 .css() 来更改属性

javascript - 究竟是什么阻止了该脚本在 IE8 中运行? (IE8问题)