Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #930621

    Hi Kriesi

    I have set up this font using the code below in the child theme function.php (found previously on your support tickets). However this brings the code to the bottom of the font list but when I select it for headings it doesn’t work. Please also see login to WP in private content below. Please advise what else I can do. Many thanks, Helen

    /* CUSTOM GOOGLE FONT */
    add_filter( ‘avf_google_heading_font’, ‘avia_add_heading_font’);
    function avia_add_heading_font($fonts)
    {
    $fonts[‘GFS Didot’] = ‘GFS Didot&subset=greek’;
    return $fonts;
    }

    add_filter( ‘avf_google_content_font’, ‘avia_add_content_font’);
    function avia_add_content_font($fonts)
    {
    $fonts[‘GFS Didot’] = ‘GFS Didot&subset=greek’;
    return $fonts;
    }

    #931254

    Hey helban,

    Which element do you need the font to apply to?

    Best regards,
    Victoria

    #931495

    Hi Victoria

    I would like to use this for h1, h2, h3, h4 headings.

    When I go into Advanced styling and select H1 in main content and alternative content and select GFS Didot from the bottom of the list, it saves but when you leave the Advanced styling page and come back it is not there (I have repeated this several times).

    On most colour sections I would like to use it as a special heading selecting H1 within the special heading in content elements.

    Regards
    Helen

    #931797

    Hi,

    Best regards,
    Victoria

    #933130

    Please could you tell me which setting to add / edit within the config file to make the change you suggest.

    By the way, I had issues with this font on another theme called ‘North’. I have since changed to your theme (which is better). The last theme developer asked me to make this change to make it work, which it did. Apparently it is to place the link directly to Google fonts as it would be on an html only site. Can you please adjust it to make it work with Enfold so I can do the same:

    function north_custom_head_content() {
    ?>
    <link href=”https://fonts.googleapis.com/css?family=GFS+Didot&#8221; rel=”stylesheet”>
    <?php
    }
    add_action( ‘wp_head’, ‘north_custom_head_content’ );

    #933414

    Hi,

    Thank you for the update.

    Please replace the filter with this one.

    add_filter( 'avf_google_heading_font', 'avia_add_heading_font');
    function avia_add_heading_font($fonts)
    {
    	$fonts['GFS Didot'] = 'GFS+Didot&subset=greek';
    	return $fonts;
    }
    
    add_filter( 'avf_google_content_font', 'avia_add_content_font');
    function avia_add_content_font($fonts)
    {
    	$fonts['Google fonts']['GFS Didot'] = 'GFS+Didot&subset=greek';
    	return $fonts;
    }
    

    Re-select the font in the theme options.

    Best regards,
    Ismael

    #933582

    Hi Ismael
    I have done (several times) that but it still doesn’t work. I have changed the Advanced Styling H1, but again when you go back to this in Theme Options it hasn’t saved. My login is on the first ticket above so perhaps you can try it?

    I have got this font to work in a static html / css site, I have got it to work on another theme ‘North’ using the code outlined above (#933130). This is now urgent as I have to either go with Enfold for this client or switch back to North.
    Please advise what I can do to make this font work.
    I value your help and support in this.
    With regards, Helen

    #934248

    Hi,

    Thank you for the info. I’m not sure why it reverts back. Please upgrade the theme from version 4.2 to the latest version 4.2.6. Let us know if that helps.

    Best regards,
    Ismael

    #934257

    Hi Ismael

    I updated the theme but it still wouldn’t ‘take’ the settings in General Font or Advanced Styling, that is you select it and it disappears. I have however, placed it in Quick CSS as an !important class for h1 and it has worked.

    Deeply frustrating and time consuming but at least it means I can keep the Enfold theme for this job.
    Many thanks for your help along the way.
    Helen

    #934495

    Hi,

    Sorry, you had to go through the troubleshooting but I’m glad it worked for you in the end.

    Please make sure you are using a child theme in case you did not instal one so your modifications stay intact in the future updates.

    Thank you for using Enfold.

    Best regards,
    Vinay

    #934496

    Hi,

    Sorry, you had to go through the troubleshooting but I’m glad it worked for you in the end.

    Please make sure you are using a child theme in case you did not instal one so your modifications stay intact in the future updates.

    Thank you for using Enfold.

    Best regards,
    Vinay

Viewing 11 posts - 1 through 11 (of 11 total)
  • The topic ‘Google font GFS Didot’ is closed to new replies.