我有字体GothamBold,GothamBook和GothamThin。我在CSS中用字体设置了font-faces,如下所示:
@font-face {
font-family: 'GothamBold';
src: url("../../fonts/GothamBold.eot"); /* IE9 Compatibility Modes */
src: url("../../fonts/GothamBold.eot?#iefix") format("embedded-opentype"), /* Safari, Android, iOS */
url("../../fonts/GothamBold.woff") format("woff"),
url("../../fonts/GothamBold.ttf") format("truetype"),
url("../../fonts/GothamBold.svg#GothamBold") format("svg");
}
@font-face {
font-family: 'GothamBook';
src: url("../../fonts/GothamBook.eot"), /* IE9 Compatibility Modes */
url("../../fonts/GothamBook.eot?#iefix") format("embedded-opentype"), /* Safari, Android, iOS */
url("../../fonts/GothamBook.woff") format("woff"),
url("../../fonts/GothamBook.ttf") format("truetype"),
url("../../fonts/GothamBook.otf") format('opentype'),
url("../../fonts/GothamBook.svg#GothamBook") format("svg");
}
@font-face {
font-family: 'GothamThin';
src: url("../../fonts/GothamThin.eot"), /* IE9 Compatibility Modes */
url("../../fonts/GothamThin.eot?#iefix") format("embedded-opentype"), /* Safari, Android, iOS */
url("../../fonts/GothamThin.woff") format("woff"),
url('../../fonts/GothamThin.ttf'); /* Safari, Android, iOS */
}
但它不适用于IE,即使它适用于Chrome,Firefox和Safari。有什么想法吗?
我尝试过使用从fontsquirrel获得的蒙特塞拉特字体工具包,但仍然无法在IE上加载它。
我在IIS中检查了我的MIME类型,每个扩展名都有以下类型: .eot - application / vnd.ms-fontobject .woff - font / x-woff .ttf - application / octet-stream .svg - image / svg + xml
它还没有在IE 8,9,10上运行。但它适用于我朋友的IE浏览器???那可能是什么???
答案 0 :(得分:1)
证明这是因为互联网选项安全设置:| - 只需转到互联网选项>安全>自定义级别>找到字体下载>选择启用。刷新你的页面和tadaaa~ ..yeah,它有效。