This is CSS code
@font-face {
font-family: 'FuturaStdBook';
src: url('site/font-face/futurastd-medium-webfont.eot');
src: local('☺'), url('site/font-face/futurastd-medium-webfont.woff') format('woff'), url('site/font-face/futurastd-medium-webfont.ttf') format('truetype'), url('site/font-face/futurastd-medium-webfont.svg#webfont') format('svg');
font-weight: normal;
font-style: normal;
}
h2 {font-family:'FuturaStdBook', sans-serif}
Can it be related to mime type?
How can i ensure my path is right?
Answers:
Thank you for visiting the Q&A section on Magenaut. Please note that all the answers may not help you solve the issue immediately. So please treat them as advisements. If you found the post helpful (or not), leave a comment & I’ll get back to you as soon as possible.
Method 1
If you’re using IIS, you’ll need to register a MIME type for the .eot extension.
- In IIS Manager, in the IIS section, open the MIME Types configuration
- Under “Actions”, click “Add…”
- Enter
.otfin the extension box, andapplication/octet-streamin the MIME type box. - Click OK
You’ll need to do this for each non-standard extension you use (.ttf is already registered, .woff is not), but that should do it!
Method 2
Try using Font Squirrel to get a bullet-proof CSS declaration for your custom font.
Method 3
The problem are the definitions of font-weight and font-style in your font-face declaration. Since h2 elements are defined in a bold face by default, the font-face declaration is not taken into account for these elements (because the browser thinks, the font file is for normal weighted weight only, which is most probably true).
Solution: You need a second font-face declaration with font-weight: bold in it or you set h2 elements to have font-weight:normal and font-style: normal.
All methods was sourced from stackoverflow.com or stackexchange.com, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0