开发者

Add new font with @font-face doesn't work

is there any error in the follow code ?

@font-face {
    fon开发者_JS百科t-family: 'raveFire';
    src: url('ravefire.eot');
    src: local('raveFire'), url('ravefire.ttf') format('truetype');
}

this code is into the file "style.css" and, the files ravefire.ttf and ravefire.eot are in the same folder than "style.css" ...

Ive tried use this new font-family in span, style, class, etc ... I also tried several browsers...

please, any help ?


I've been using font-face quite a bit recently and I've not seen the "local" reference, try it without, i.e.:

@font-face {
    font-family: 'raveFire';
    font-style: normal;
    font-weight: normal;
    src: url('ravefire.eot') format('eot'), url('ravefire.ttf') format('truetype');
}

Make sure your fonts are in the same folder as the page, or use absolute paths to them.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜