Using Specialized Fonts in CSS

APD Toronto
APD Toronto used Ask the Experts™
on
Hi Experts,

I've never used specialized fonts in my CSS, would the following be correct?

@font-face {
    font-family: "Clibri";
    src: url(calibri.ttf) format("truetype");
}
* { 
    font-family: Calibri, Verdana, Tahoma;
}

Open in new window


I know that Calibri has 5-6 files, but I just copied the  main .ttf file in the same folder as my .css file. Is that correct?

Lastly, how can I tell if the browser is using my calibri, or the browser's default font?

Thanks
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Full Stack Developer
Commented:
Try this ;)

There is a small typo in the code font-family in font-face should be Calibri:

@font-face {
    font-family: "Calibri";
    src: url(calibri.ttf) format("truetype");
}
* { 
    font-family: Calibri, Verdana, Tahoma;
}

Open in new window

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial