treehouse : what would you like to learn today?
Web Design Web Development iOS Development

Font import to my html page

  • i want to import font in to my html page. i have look more site using font import using css @font-import{ }. nut there any example cannot work

    i am here declared my css code in my css file:
    @font-face {
    font-family: "Sketch Block";
    src: url("../Sketch Block.ttf") format("truetype");
    }

    the font is in my root folder.

    you have any smple file can u show or post in twitter . this is very urgent rewuirement.
  • @font-face isn't widely supported currently, what browser are you using to test with ?
  • @font-face is supported by the latest safari and opera I think...
    for firefox and the rest of crappy IE versions try using sifr3 or 2.07
  • "JayX" said:
    @font-face isn't widely supported currently, what browser are you using to test with ?

    i am using firefox 3.0 version and Ie7
  • That'll be why then, FireFox 3 doesn't pass CSS3 validation yet (by quite a way) and IE7 is lightyears behind. Only Opera and Safari (and Chrome, I imagine due to webkit) hit all the validators as per Nick's post.