-1

I found a service that allow me to download web fonts: https://www.fontsquirrel.com/fonts/daniel

I am not a web developer but I am helping to someone to figure out what went wrong.

Here is a web site that uses custom fonts: http://senschild.com

I've implemented:

@font-face{

font-family: 'Daniel-Regular';

src: url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.eot');

src: url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.eot?iefix') format('eot'),

url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.woff') format('woff'),

url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.ttf') format('truetype'),

url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.svg#webfont') format('svg');

}

but it does not work for me. The font is still system on the page.

What I did as well:

I also fixed this one as you said and fixed this part '../ as we don't need to move up as Maneesh said. Also I've edited css by removing font-family:JakobCTT; from body, but still does not work. I even added english words assuming that the font only for english characters.

Matrosov Oleksandr
  • 25,505
  • 44
  • 151
  • 277
  • Have you ensured that the urls are pointing to the correct place? I don't see any fonts being loaded in the resources for the link you provided. Remember that `..` means move one folder up, so if you have added this code on your HTML page, you need to reference `fonts/[FILE_URL_HERE]` – Maneesh Jun 20 '16 at 09:14
  • @Maneesh thanks yea indeed, just fixed it, but still does not work. – Matrosov Oleksandr Jun 20 '16 at 09:17
  • http://senschild.com here i can't find font-face and relate font family. – Germano Plebani Jun 20 '16 at 09:20
  • @GermanoPlebani just updated it, but still does not work – Matrosov Oleksandr Jun 20 '16 at 09:29
  • Here you can find many solution: http://stackoverflow.com/questions/30442319/failed-to-decode-downloaded-font – Germano Plebani Jun 20 '16 at 09:45
  • @MatrosovAlexander: If you having issues with the font file itself, there could be a few areas of failure, the file being one. You should also ensure that the server you are using has MIME types added to its config to serve the various file formats correctly. – Maneesh Jun 20 '16 at 11:20

2 Answers2

0

The font files you are using appear to be corrupt, as Failed to decode downloaded font indicates. I've had this problem many times before when using the webfont generator on https://www.fontsquirrel.com.

Edit: If you download the .OTF file and generate the webfont with https://www.web-font-generator.com/ it appears to work just fine.

Fabian Wennink
  • 137
  • 3
  • 13
-1

Here is your fix: Add style to the html elements you want to apply the font for. If you want the font to be applied for the whole webpage, then add the following style for body tag either in html or css.

font-family: 'Daniel-Regular';

Try this:

url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.eot?#iefix')

instead of

url('../fonts/daniel_regular_macroman/Daniel-Regular-webfont.eot?iefix')

There should be a ?#iefix not just a ?iefix

Anoop Garlapati
  • 257
  • 2
  • 14
  • thanks ok I also fixed this one as you said and fixed this part `'../` as we don't need to move up as Maneesh said. Also I've edited css by removing font-family:JakobCTT; from body, but still does not work. I even added english words assuming that the font only for english characters. – Matrosov Oleksandr Jun 20 '16 at 09:28
  • @MatrosovAlexander Try removing the `#iefix` part and check. That might work as well. – Anoop Garlapati Jun 20 '16 at 09:43