Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS @font-face issue…

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #28944
    hotrun
    Member

    Hi to all!!

    At the moment my problem is: I uploaded an external font for first on my pc and then on the server and I added this code into my html page:

    Code:
    @font-face{
    font-family: Anmari;
    src: url(‘Anmari.ttf’);

    }

    h1{
    font-family: Anmari;
    color: #fff;
    text-align: center;
    font-size: 30px;
    font-weight: normal;
    }

    So we can find this page and the font on the server, the problem is that other computers and browsers don’t read the font… WHY? I am going just a bit mad ;) Thx to all!!!

    #75180
    leonzinger
    Member

    Hi there,

    Your code looks good but…

    @font-face{
    font-family: Anmari;
    src: url(‘Anmari.ttf);
    }

    this little guy in red look odd… so maybe that’s the problem? or maybe you don’t have permissions on that file at the hosting server?

    #75189
    noahgelman
    Participant

    I believe the above comment is right, that’s not a proper apostrophe. Backspace and retype it and you should be good. Also make sure your file path is right and that it doesnt need a / or a ../ on it.

    #75208
    hotrun
    Member

    Hi guys!!

    All of your comments are so udeful I thank you!!

    The apostrophe was so wrong ( but I don’t know why I checked if it’s depend on the script ); it’s not so clear about the "smily-face" yet ( how can I add a smily-face??? ) but I am reading several topics for example one by Paul Irish and one by Jonathan Snook and more so I am going into the @font-face ‘situation’ and wow! it’ so complex…

    Anyway, I’ll use the last rule posted and thx again guys!! Have a good day!!

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘CSS’ is closed to new topics and replies.