Error loading source: OTS Parsing error: cmap: Failed to parse format 4

1

I'm having trouble for the browser to use a custom font! In the css folder I have the fonts folder, and inside the fonts folder is the file prompt.ttf but at the time I upload the file to the server, I do the test and the font does not appear. It is replaced by the default font sans-serif .

INDEX CSS Code:

@font-face {
font-family: 'prompt';
src: url('fonts/prompt.ttf');
}
#name {
font-family: 'prompt', sans-serif; 
font-size:10px;
text-indent:10px;
text-align:left;
z-index:1;
position:absolute;
font-weight:normal;
width:120px;
height:20px;
top:110px;
right:75px;
border-radius: 5px 5px 5px 5px;
-moz-border-radius: 5px 5px 5px 5px;
-webkit-border-radius: 5px 5px 5px 5px;
border: 0px solid #000000;
}

Error Print:

    
asked by anonymous 25.04.2016 / 07:58

1 answer

1

In fact I solved the error by adding the font format I wanted to use, (true type).

This is what CSS is like:

font-family: 'prompt';
src: url('fonts/prompt.ttf') format('truetype');

I tested it with open type and it also worked:

font-family: 'menufont';
src: url('fonts/myriad.otf') format('opentype');

Anyway, just add the format that stopped the error!

    
26.04.2016 / 00:08