问答详情
源自:2-5 导航页背影动画制作(@font-face实现小icon)

字体和css文件在同级,为什么我的字体导入不成功呢

@font-face{
    font-family: "Raphaelicons";
    src:url("../fonts/raphaelicons-webfont.eot") format("eot"),
        url("../fonts/raphaelicons-webfont.ttf") format("truetype"),
        url("../fonts/raphaelicons-webfont.woff") format("woff"),
        url("../fonts/raphaelicons-webfont.svg") format("svg");
    font-weight: normal;
    font-style: normal;
}    

提问者:QAQQQQ 2016-04-10 17:10

个回答

  • chendidi
    2016-07-30 20:22:52

    如果fonts和main。css文件在同级,就没必要加../了

  • 旅行的癞蛤蟆
    2016-04-12 16:58:21

    同级就直接引用字体文件就行了,不必加父级目录额