I had troubles with a @font-face these days. My font was not displaying in IE11, but in all others.
Turned out that removing the "woff2" font solved my problems and the font displayed normally.
My question now is: Why could that be the solution? What is going on in IE11s mind, that removing a simple "woff2" tag could be the answer? I mean, normally I read about .htaccess files and other things which are really not easy to find out...
Does IE11 try to load the woff2 first?
Fonts are provided in WOFF and WOFF2 format, which collectively cover all major browsers: Chrome (on desktop and iOS/Android), Firefox, Safari (on Mac and iOS), Internet Explorer, Edge, and others.
It compresses the files and is supported by all modern browsers. Web Open Font Format 2 (WOFF2): WOFF2 is an update to the original WOFF format. Developed by Google, this is considered the best format of the bunch because it offers smaller file sizes and better performance for modern browsers that support it.
It is a World Wide Web Consortium Recommendation and is clearly the future of font formats. WOFF2 is the next generation of WOFF. The WOFF2 format offers a 30% average compression gain over the original WOFF. Because it still just a recommended upgrade, it does not have the wide support of WOFF.
IE 11 use woff instead of woff2. If you want maximum compatibility use this:
@font-face {
font-family: 'MyWebFont';
src: url('webfont.eot'); /* IE9 Compat Modes */
src: url('webfont.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('webfont.woff2') format('woff2'), /* Super Modern Browsers */
url('webfont.woff') format('woff'), /* Pretty Modern Browsers */
url('webfont.ttf') format('truetype'), /* Safari, Android, iOS */
url('webfont.svg#svgFontName') format('svg'); /* Legacy iOS */
}
For reference: CSS Tricks - Using @font-face
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With