我有两种自定义字体。两种字体在Safari(OSX和IOS)以及iOS和IE11上的Chrome和Firefox上运行良好。 Font'Underwood'在OSX上的Chrome,Firefox和Opera上失败,错误“无法解码下载的字体”。 Font'Avenir'适用于所有浏览器。
字体在本地托管。我尝试了相对路径和绝对路径。我已经下载了一个替代'underwood'并将ttf转换为otf。一切都没有用。
有人解决方案吗?
@font-face {
font-family: 'Avenir';
font-style: normal;
font-weight: normal;
src: url('fonts/Avenir/avenir-light.woff') format('woff'),
url('fonts/Avenir/avenir-light.ttf') format('truetype');
}
@font-face {
font-family: 'Underwood';
font-style: normal;
font-weight: normal;
src: url('//www.dekipgallery.nl/includes/fonts/Underwood/Underwood.eot');
src: url('//www.dekipgallery.nl/includes/fonts/Underwood/Underwood.woff') format('woff'),
url('//www.dekipgallery.nl/includes/fonts/Underwood/Underwood.ttf') format('truetype'),
url('//www.dekipgallery.nl/includes/fonts/Underwood/Underwood.otf') format('opentype'),
url('//www.dekipgallery.nl/includes/fonts/Underwood/Underwood.eot?#iefix') format('embedded-opentype'),
url('//www.dekipgallery.nl/includes/fonts/Underwood/Underwood.svg#my_underwoodregular') format('svg');
}