Monday, August 25, 2014

How to use custom font in wordpress?

Using non-standard fonts inside WordPress requires two additional steps:
  1. downloading and installing the font
  2. calling the font using @font-face


The CSS selector @font-face allows you to add support for custom fonts by including the font file in your CSS file. To add custom support for nearly any custom font, type the following into your site’s main style.css file:

 
 
 
@font-face{
font-family:karate;
src:url('/www/wp-content/themes/thesis-bp-child/custom-1/fonts/Karate.ttf') format ("truetype");
}


Simply input the name of the new font you’ve uploaded within the font-family selector like this:
 
 
 
#site-title a {font-family:karate;}

No comments:

Post a Comment