INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

Embedding Fonts

How do I embed a Font on my webpage? by cian
Posted: 1 Feb 02 (Edited 19 Feb 03)

**This information is quite old and I have not recently checked to see if it is still valid**

To embed a font type on a WebPage first select the font you want to embed either from your hard drive or download it from the Internet.  Then create an embedded font file(below). And lastly attach the font to your style sheet.



Creating the Embedded File
You need to download software to create an embedded font file which can be in two formats  .pfr  or  .eot.


Portable Font Resources (.pfr): TrueDoc for Nav 4.0+ and IE 4.0+ on Windows, Mac, and Unix platforms
Download the software from  http://Bitstream.com

Embeddable Open Type (.eot): Compatible only with Explorer 4.0+ on the Windows platform
Download the software from http://www.microsoft.com/typography/web/embedding/weft3/default.htm



Next we need to embed the file using CSS.
This can be done 2 ways

Into the HEAD section of your document insert:


Example with True Doc

<link rel="fontdef" src="my-fancy-font.pfr">


To work in IE4 and above, you need to add a pointer to an ActiveX control immediately after the LINK tag or the easier option: create an OpenType file for Explorer and refer to both types on your page.

TrueDoc fonts stay within the browser: you can't download them to your system


Example with Open Type


<STYLE TYPE="text/css">
<--!
@font-face {
  src:url(myfonts/fontname.eot);
}
-->
</STYLE>






I apologise for any errors or ommisions.
Questions or feedback would be greatly appreciated.

+


Back to HTML, XHTML & CSS FAQ Index
Back to HTML, XHTML & CSS Forum

My Archive

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close