Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Apr 2014
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    CSS Font embedding issues.

    I'm currently trying to embed a TTF font into my page. For some reason it doesn't seem to embed, i have used Check Browser Compatibility, Cross Platform Browser Test - Browsershots to view my page in a multitude of browsers and none seem to pick up the embedded font.

    My font face CSS is:

    Code:
    @font-face 
    {
    font-family: 'Tw Cen MT';
    src: url('tw.eot');
    src: url('tw.eot?#iefix') format('embedded-opentype'),
         url('tw.woff') format('woff'),
         url('tw.ttf') format('truetype'),
          url('tw.svg#helveticaregular') format('svg');
    font-weight: normal;
    font-style: normal;
    }
    An example of the font-family in use in my CSS is:

    Code:
    p.toptext
    {
    font-size:17px;
    font-family:"Tw Cen MT", "Helvetica";
    font-weight:bold;
    color:#d5d3d3;
    letter-spacing:0.5ex;
    margin-top:22px;
    }
    The font is simply located in my directory "tw.ttf".

    I have downloaded Firefox and checked my site in that, the font isn't showing up. I am positive Firefox allows embedded TTF fonts.

    My site is: Crooked Cartoon - Print & Design

    Thanks for any help in advance!

  • #2
    New Coder
    Join Date
    Mar 2005
    Location
    Croatia
    Posts
    20
    Thanks
    1
    Thanked 1 Time in 1 Post
    The font is simply located in my directory "tw.ttf".
    your css file is here: http://www.crookedcartoon.co.uk/css/print.css

    if you link to the font like this:

    @font-face
    {
    font-family: 'Tw Cen MT';
    src: url('tw.eot');
    src: url('tw.eot?#iefix') format('embedded-opentype'),
    url('tw.woff') format('woff'),
    url('tw.ttf') format('truetype'),
    url('tw.svg#helveticaregular') format('svg');
    font-weight: normal;
    font-style: normal;
    }


    it will assume the font is located in http://www.crookedcartoon.co.uk/css/ folder.
    Hit me up for cheap but quality html/css conversions/rebuilds. Ok, let me see what you've got

  • #3
    New to the CF scene
    Join Date
    Apr 2014
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi,

    I too have the same problem. Please help me with that.

    http://www.pioneer0303.com
    Last edited by VIPStephan; 04-04-2014 at 10:42 PM. Reason: removed link

  • #4
    New to the CF scene
    Join Date
    Apr 2014
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    FIXED:

    Code:
    @font-face 
    {
    font-family: 'Tw Cen MT';
    src: url('../tw.eot');
    src: url('../tw.eot?#iefix') format('embedded-opentype'),
         url('../tw.woff') format('woff'),
         url('../tw.ttf') format('truetype'),
         url('../tw.svg#helveticaregular') format('svg');
    font-weight: normal;
    font-style: normal;
    }
    Thanks to the help above, it is trying to locate my font within the same CSS folder, if you add '../' to the beginning of your path, it should fix it.


  •  

    Tags for this Thread

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •