字体不工作在ie [英] font face not working in ie

查看:201
本文介绍了字体不工作在ie的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个html布局并使用css3 @ font-face 。这是我的代码

I have created a html layout and using css3 @font-face. Here is my code

@font-face {
    font-family: 'MyriadProRegular';
    src: url('myriad.eot');
    src: url('myriad.eot?#iefix') format('embedded-opentype'),
         url('myriad.woff') format('woff'),
         url('myriad.ttf') format('truetype'),
         url('myriad.svg#MyriadProRegular') format('svg');
}

我正在使用

font-family: 'MyriadProRegular';

它在所有浏览器都工作接受IE。请帮助。

it's work in all browsers accept IE. Please help.

推荐答案

我不能推荐Font Squirrel。只是运行他们的字体生成器,你会得到的代码,将工作在IE。如果你缺少一种字体文件类型,它甚至为你。在过去,这节省了我很多时间,我不能推荐它。

I can't recommend Font Squirrel enough for this. Just run through their Font Face generator and you'll get code that will work in IE. If you're missing a font file type it even makes that for you. It's saved me a lot of time in the past and I can't recommend it enough.

http://www.fontsquirrel.com/fontface/generator

这是来自Font Squirrel的工作交叉浏览器:

This is from Font Squirrel and works cross browser:

@font-face {
    font-family: 'NimbusSanConD-Lig';
    src: url('fonts/228BFB_1_0.eot');
    src: url('fonts/228BFB_1_0.eot?#iefix') format('embedded-opentype'),
         url('fonts/228BFB_0_0.woff') format('woff'),
         url('fonts/228BFB_0_0.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

这篇关于字体不工作在ie的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆