这是有问题的网站: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 中运行良好。
关于html - ie8 在第一页加载或刷新时不呈现@font-face 字体,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21123067/