Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #341130

    Hi Guys!

    Please can you tell me how to add a Google Font to the theme. I want to add PT Mono as my p font.

    Thanks you very much indeed.

    Regards,

    Christian

    #341408

    Hi jaroljmek!

    Thank you for using Enfold.

    Please use this on functions.php:

    add_filter( 'avf_google_heading_font',  'avia_add_heading_font');
    function avia_add_heading_font($fonts)
    {
    $fonts['PT Mono'] = 'PT Mono';
    return $fonts;
    }
    
    add_filter( 'avf_google_content_font',  'avia_add_content_font');
    function avia_add_content_font($fonts)
    {
    $fonts['PT Mono'] = 'PT Mono';
    return $fonts;
    }

    Regards,
    Ismael

    #341424

    Hi there!

    Thanks for this. Can you please send me the path to the function.php file? I can’t find it. Also, can you tell me where in the file I should insert this code?

    Thanks very much.

    Regards,

    Christian

    #341561

    Changes to functions.php in a parent theme will typically be overwritten (lost) when you update your theme. To avoid this, you should set up a child-theme and make changes to that instead of the parent theme. You can download a ready-made child theme here – http://kriesi.at/documentation/enfold/downloads/

    The mods have also made a video available on this page – http://kriesi.at/documentation/enfold/videos/

    Once you’re working with a child theme, in the admin area select Appearance > Editor, then click on Theme Functions (functions.php).

    Dropping code into your functions.php has the potential to take your whole site offline. If that happens you’ll almost certainly need to have file access in order to resolve the problem. If you’re not familiar with using functions.php please ensure your site is fully backed up beforehand, and if at all possible test this out on a Staging/test site.

    #341951

    Hi!


    @jaroljmek
    : The functions.php file is located on Appearance > Editor > Theme Functions (functions.php).

    Best regards,
    Ismael

    #343816

    Is there an easier, safer way to add a Google font?

    #343821

    also it seems all the fonts come out BOLD. I want to make H3 Not bold– and all fonts for that matter.

    #344818

    Hey!

    You can use a child theme to make changes to your site.

    Here’s a link to download a starter child theme:
    http://bit.ly/enfold-child

    With regards to removing bold styles apply the CSS property font-style: normal to any required element. Use !important if required.

    Cheers!
    Arvish

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.