Solved

Web Fonts - @font-face

Posted on 2013-12-17
3
613 Views
Last Modified: 2013-12-17
I have been supplied some fonts for a website.

They are ".otf" files.

I have read this article regarding how to install and use the fonts on a website:

http://www.fontspring.com/support/installing_webfonts/how-do-i-use-the-webfonts

It looks as though if I bought the fonts directly myself they would include other file types like “.woff”, “.ttf” and “.svg”.

I only have the  ".otf" files. Do I need all of them for the web fonts to work correctly on my website or can I just use the ".otf" files?

When are each of these file types used? Are they browser specific?

Also do I use @font-face or is there another font solution that I can use.

I have used google fonts in the past, but they do not have this font in there library or can any font be used via google fonts if you buy the licence?

All advice appreciated.
0
Comment
Question by:petewinter
  • 2
3 Comments
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 500 total points
ID: 39725223
That's a good article.  In my experience, you need all the fonts shown in the article except maybe the svg version.  'otf' by itself is not enough.  IE uses the 'eot' and you need both versions shown in the example code, Firefox uses the 'woff', and Chrome will use either the 'ttf' or the 'svg'.  In my application, the CSS file for the web-fonts needed to be in the same directory as the fonts themselves.

The Google fonts are only the ones that they supply.  You can't buy a font from Adobe or Lintype and upload it to Google.  And a lot of fonts are not licensed for use as 'web-fonts' anyway.
0
 

Author Closing Comment

by:petewinter
ID: 39725261
Perfect. Many thanks
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39725269
You're welcome, glad to help.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying 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

Suggested Solutions

Why do we like using grid based layouts in website design? Let's look at the live examples of websites and compare them to grid based WordPress themes.
This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

856 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