我在我的web项目中集成了一个字体。下面是CSS代码:
@font-face {
font-family: 'vladimirscriptefregular';
src: url('fonts/vladimirscriptef-webfont.eot');
src: url('fonts/vladimirscriptef-webfont.eot?#iefix') format('embedded-opentype'),
url('fonts/vladimirscriptef-webfont.woff') format('woff'),
url('fonts/vladimirscriptef-webfont.ttf') format('truetype'),
url('fonts/vladimirscriptef-webfont.svg#vladimirscriptefregular') format('svg');
font-weight: normal;
font-style: normal;
}我的问题是,字体在Firefox中不会显示,而是显示Times New Roman。在所有其他浏览器中,字体都可以正确显示。
有没有人看到我的代码中缺少了什么?
发布于 2014-06-03 23:53:18
尝试下面的代码:
@font-face {
font-family: 'vladimirscriptefregular';
-moz-font-family:'vladimirscriptefregular';
src: url('fonts/vladimirscriptef-webfont.eot');
src: url('fonts/vladimirscriptef-webfont.eot?#iefix') format('embedded-opentype'),
url('fonts/vladimirscriptef-webfont.woff') format('woff'),
url('fonts/vladimirscriptef-webfont.ttf') format('truetype'),
url('fonts/vladimirscriptef-webfont.svg#vladimirscriptefregular') format('svg');
font-weight: normal;
-moz-font-weight:normal
font-style: normal;
-moz-font-style:normal
}发布于 2022-01-20 19:04:32
Firefox有一个可以在其白名单中使用的字体列表。
在地址栏中键入“about:”即可访问
对于windows,默认位置为"C:\Windows\Fonts“
https://stackoverflow.com/questions/24019411
复制相似问题