Solved

How to use @font-face in IE?

Posted on 2010-09-21
5
532 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
  • 2
  • 2
5 Comments
 
LVL 1

Accepted Solution

by:
Funcod earned 500 total points
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
@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
Comment Utility
thank you
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Help in CSS 5 35
Spacing Makes the DIV Navigation sub-menu disappear 6 39
Custom CSS for Bootstrap Nav Bar 3 30
Phone Dialer 5 33
When applying CSS to your HTML, there are many different ways to select which element(s) the CSS applies to.  Some of these selectors are more commonly known and used than others - Here are the more common ones: #X - Matches an ID of X .X - Matche…
Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer …
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
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…

762 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

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now