[英]Custom fonts not displayed in Internet Explorer
我的網站使用自定義字體。 它們適用於除Internet Explorer(版本11.0.9600)之外的所有瀏覽器。
CSS代碼:
@font-face {
font-family: 'almoni-dl';
font-weight: 700; /*(bold)*/
font-style: normal;
src: url('https://assets.mywebsite.com/fonts/almoni-dl-aaa-700.eot?#iefix') format('embedded-opentype'),
url('https://assets.mywebsite.com/fonts/almoni-dl-aaa-700.woff') format('woff'),
url('https://assets.mywebsite.com/fonts/almoni-dl-aaa-700.ttf') format('truetype');
}
html {
font-family: 'almoni-dl','Trebuchet MS',Helvetica,sans-serif;
}
到目前為止我嘗試過的:
Access-Control-Allow-Origin:*
。 我也嘗試過使用相對路徑,沒有運氣。 我還嘗試了以下語法:
@font-face { font-family: 'almoni-dl'; font-weight: 700; /*(bold)*/ font-style: normal; src: url('https://assets.kalir.co.il/fonts/almoni-dl-aaa-700.eot'); src: url('https://assets.kalir.co.il/fonts/almoni-dl-aaa-700.eot?#iefix') format('embedded-opentype'), url('https://assets.kalir.co.il/fonts/almoni-dl-aaa-700.woff') format('woff'), url('https://assets.kalir.co.il/fonts/almoni-dl-aaa-700.ttf') format('truetype'); }
還有什么可能是錯的?
在css的font-family屬性中,嘗試鍵入字體的實際全名,如果不起作用,請嘗試使用完整文件名(減去擴展名)作為font-family。 如果字體系列名稱與預期不同,IE已知問題找到字體!
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.