| Regular Member
Join Date: May 2008 Location: Haifa, Israel
Posts: 630
My Mood: | you'll have to add the font to the website root folder
or a sub-folder (doesn't matter - but must be inside root)
and this content might help: Quote:
@font-face
The @font-face at-rule is used for a variety of purposes, but essentially it is used to specify the correct behavior when a font is not available locally.
In general, the @font-face at-rule is used for this purpose. This follows a form similar to this @font-face {property: value; property: value}.
There may be any number of @font-face rules in a stylesheet.
Font selection properties
font-family
This specifies the name of a font that you are describing. For example, @font-face {font-family: Arial}. Multiple font families can be specified; e.g., @font-face {font-family: sans-serif, Arial}. It takes the same values as
font-style, font-size, font-weight, font-stretch, font-variant
This specifies the type of font that is being described.
They take the same values as their equivalent normal properties, except they can take a comma-separated list.
For font-style, font-size, font-stretch and font-weight, however, the 'all' value is also valid, which indicates that all values are matched.
However, values that relate to another value are not valid (e.g., smaller and bolder), and neither are the font size keywords 'large', 'small', etc.
E.g., font-weight: 100, 300, 500, 600, 700, 800, 900.
The initial value for font-size, font-weight and font-style is all. For font-variant and font-stretch it is normal.
Font retrieval properties
If it is important that a specific font is used in viewing your document, you should use the properties that specify its location and characteristics.
src
The src property specifies the location of a font: It follows this basic syntax: src: url(address1). Thus to be specify that you can find the 'foo' font at Get the 411 on Anyone with Free White Pages, People Search and Online Directory, you would use @font-face {font-family: foo; src: url(www.foo.com)}.
If you wish, you can specify the format of the font. E.g., @font-face {font-family: foo; src: url(Get the 411 on Anyone with Free White Pages, People Search and Online Directory) format("footype")}. To be specify several uris for browsers that support different font types, you separate them with commas. E.g., @font-face {font-family: foo; src: url(Get the 411 on Anyone with Free White Pages, People Search and Online Directory) format("footype"), src(foo2.com) format("foo4")}.
Note that the format must be in quotes.
Finally, you can specify the name of a local font to match. E.g., to specify that when an element is specified as being in Times, Times New Roman should be used, you would type:
@font-face {font-family: Times;
src: local("Times New Roman")}
Note again that the font name must be in quotes, even if it doesn't include whitespace.
Here's another example, which specifies the location of italic Foo.
@font-face {font-family: Foo;
src: url(http://www.foo.com);
font-style: italic}
Since font-size is initially all, the font will be used at all sizes; but will not be used for small-caps or stretched text, since font-variant and font-stretch are initally set to normal.
| from RichInStyle.com CSS2 tutorial - @font-face |