Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #369114

    Hi there!

    How can I see all fonts used by Enfold at one place so that I can choose new one from?

    Thanks!

    Orhan

    #369124

    Merhabalar!

    Unfortunately currently it is not possible to preview all available fonts. But you can look up and preview them on http://www.google.com/fonts

    Best regards,
    Yigit

    #369129

    Merhaba Yigit!

    Thanks for quick response. Is there any way to add new Google Font easily?

    Thanks,

    Orhan

    #369155
    #369164

    Hey Orhan!

    Try adding this at the very end of your theme / child theme functions.php file:

    add_filter( 'avf_google_heading_font',  'avia_add_custom_font');
    add_filter( 'avf_google_content_font',  'avia_add_custom_font');
    function avia_add_custom_font($fonts) {
    	$fonts['Source Sans'] = 'Source Sans Pro:300,400';
    	return $fonts;
    }

    Cheers!
    Josue

    #369424

    Hi Again,

    I am confused. Can you please explain how I add Raleway font (Latin) especially?

    Thanks!
    Orhan

    #369546

    Hey!

    Raleway font is already available. Can you post the link to your website please?

    Best regards,
    Yigit

    #369561

    I meant Raleway Dots. I need to see a code which belongs to a new font :)

    Thank you

    #369567

    Hi!

    Please add following code to Functions.php file

    add_filter( 'avf_google_heading_font', 'avia_add_heading_font', 10);
    function avia_add_heading_font($fonts)
    {
    $fonts['Raleway Dots'] = 'Raleway Dots:400';
    return $fonts;
    }
    
    add_filter( 'avf_google_content_font', 'avia_add_content_font');
    function avia_add_content_font($fonts)
    {
    $fonts['Raleway Dots'] = 'Raleway Dots:400';
    return $fonts;
    }

    Cheers!
    Yigit

    #374507

    Selam Yigit,

    I added this code but get an error message below.

    Fatal error: Cannot redeclare avia_add_heading_font() (previously declared in /home/erkuto/insanayatirim.com/wp-content/themes/enfold-child/functions.php:9) in /home/erkuto/insanayatirim.com/wp-content/themes/enfold-child/functions.php on line 54

    What’s wrong with it?

    Thanks,
    Orhan

    #374632

    Hi!

    Thank you for using Enfold.

    Looks like you added the code before on the child theme’s functions.php. Remove it.

    Best regards,
    Ismael

    #374684

    Hi,

    I removed it but how could I add the code?

    #374888

    Hey!

    Please change “avia_add_heading_font” to something like “avia_add_heading_font_second” as following

    add_filter( 'avf_google_heading_font', 'avia_add_heading_font_second', 10);
    function avia_add_heading_font_second($fonts)
    {
    $fonts['Raleway Dots'] = 'Raleway Dots:400';
    return $fonts;
    }
    
    add_filter( 'avf_google_content_font', 'avia_add_content_font_second');
    function avia_add_content_font_second($fonts)
    {
    $fonts['Raleway Dots'] = 'Raleway Dots:400';
    return $fonts;
    }

    Function names should be unique

    Best regards,
    Yigit

    #374974

    It worked! Teşekkürler :)

Viewing 14 posts - 1 through 14 (of 14 total)
  • The topic ‘Font Family’ is closed to new replies.