Solved

How to use @font-face in IE?

Posted on 2010-09-21
5
538 Views
Last Modified: 2012-05-10
Hello, here is my code:

@font-face {
      font-family: blackjack;
      src: url('fonts/blackjack.eot');
      src: url('fonts/black_jack.ttf') format('truetype');
}

but this wont work in IE, but it will in Firefox.  This works in IE though:

@font-face {
      font-family: blackjack;
      src: url('fonts/blackjack.eot');
}

but then, obviously, it will not show in Firefox, or other browsers.  Can someone please let me know how to fix this?
0
Comment
Question by:FairyBusiness
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 1

Accepted Solution

by:
Funcod earned 500 total points
ID: 33727753
try this:

@font-face {
  font-family: 'blackjack';
  src: url('fonts/blackjack.eot');
  src: local('¿'),
         url('fonts/black_jack.ttf') format('truetype');
}
0
 

Author Comment

by:FairyBusiness
ID: 33727765
why put the local?? and what is this ('?')

I dont know how to make an up-side-down question mark. . . just curious!
0
 
LVL 1

Expert Comment

by:Funcod
ID: 33727798
replace the ¿ by the smiley (alt+1 if you are on windows)

check this url for info:
http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
0
 
LVL 3

Expert Comment

by:daddotnet
ID: 33727812
@font-face{ /* for IE */
font-family:MyFont;
src:url(myfont.eot);
}
@font-face { /* for non-IE */
font-family:MyFont;
src:url(http://:/) format("No-IE-404"),url(myfont.ttf) format("truetype");
}

-DdN
0
 

Author Comment

by:FairyBusiness
ID: 33728083
thank you
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When writing CSS, there are a few simple rules that will make your life easier.    1. Using ‘* {box-sizing:border-box;}’. Using this will wrap all your elements in a nice little compact box-model that will give you the width you want, like so... …
Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
In this tutorial viewers will learn how to customize the background color and font color of highlighted text using the ::selection element in CSS Begin by defining the selected text as an element in CSS by typing "::selection": Style the ::selection…
Suggested Courses

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question