“How to use .OTF (or other desktop) fonts on your website?”
If you would like to use your desktop fonts on your website, do this!
CSS
- Select your fonts and place them on your server.
- Copy and paste the code below into your stylesheet.
- Replace
'FONT1'infont-familyon both@font-faceandpwith your own font name. - You may change
normaltoboldif necessary.
@font-face {
font-family: 'FONT1';
src: url("../fonts/YOUR-FONT-LOCATION.otf") format("opentype");
font-weight: normal;
font-style: normal;
}
p {
font-family: 'FONT1', sans-serif;
}
