4

not a huge bug, but it was my most recent one. was building a website and I wanted a custom font, so I put in
@font-face {
font-family: "Font";
src: url ("fonts/font.otf") format("opentype");
}
but this wasn't working. looked for about a day (while working on other stuff) finally found an article that said I needed absolute paths to the font rather than relative paths. so /css/fonts/font.otf worked

Comments
  • 1
    Hm yeah, but its actually a rooted relative path?
  • 1
    to true. it's actually at /srv/http/css/fonts
  • 2
    Not true the URL is relative to the CSS file... Keep in mind where it compiles to.
    So, not relative to the less file or sass file. Just relative to the final file.
  • 1
    @lewdogg maybe technically you are right, but on every browser I tested, it didn't work.
Add Comment