@font-face {
font-family: "Gotham";
src: font_path("gotham-rounded-medium.otf") format("opentype");
}
我的 CSS 文件中有这个,但我仍然无法获取字体。有帮助吗?
最佳答案
你需要指定url,而且我相信它是font-path,而不是font_path
@font-face {
字体系列:“哥谭”;
src: url(字体路径("gotham-rounded-medium.otf")) 格式("opentype");
}
更多信息:http://aokolish.me/blog/2011/12/24/at-font-face-with-the-asset-pipeline/
关于css - 无法获取 CSS 字体,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32508259/