[Support request] How to remove Google Fonts

Home Forums Support [Support request] How to remove Google Fonts

Home Forums Support How to remove Google Fonts

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #2354829
    Haissam

    Hello,
    I want to completely remove google fonts and use default system fonts instead such as Arial.
    The idea is to improve loading time for my pages.
    Can you please let me know how in a step by step as usual?

    #2354843
    Fernando
    Customer Support

    Hi Haissam,

    If no Google Font is used, Google font wont be loaded/enqueued by default.

    You can also try doing so with the snippets here: https://docs.generatepress.com/article/remove-google-fonts/

    #2354846
    Haissam

    So if i make sure in the customizer-> typography that there are not google fonts selected, it should stop loading google fonts libraries?

    #2354875
    Fernando
    Customer Support

    Yes, it should.

    However, if you also set a Google Font through the Block settings of GenerateBlocks Block, you should also remove that.

    When no Google font is loaded from GP and GB, Google font wont be loaded in your site.

    #2384584
    Bettina

    I have the same problem and would like to remove Google Fonts from customizer.
    Google Fonts are stored local, in GenerateBlocks the Fonts are removed.

    My function.php from generatepress_child has following code:

    add_action( ‘admin_init’, function() {
    add_filter( ‘generate_google_fonts_array’, ‘__return_empty_array’ );
    } );
    add_filter( ‘generate_typography_default_fonts’, function( $fonts ) {
    $fonts[] = ‘Open Sans’;

    return $fonts;
    } );

    But Google Fonts are still in the customizer and still there is still a link to google:

    <meta name=”viewport” content=”width=device-width, initial-scale=1″><link rel=’dns-prefetch’ href=’//fonts.googleapis.com’ />

    <link rel=’stylesheet’ id=’generateblocks-google-fonts-css’ href=’https://fonts.googleapis.com/css?family=Open+Sans:300,300italic,regular,italic,600,600italic,700,700italic,800,800italic&display=swap&#8217; media=’all’ />

    What can I do? The Website is https://mootiv.de

    #2384712
    Ying
    Staff
    Customer Support

    I have the same problem and would like to remove Google Fonts from customizer.

    1. Make sure you are using the dynamic typography system of GP:
    https://docs.generatepress.com/article/dynamic-typography-overview/

    If you are still using the old typography system, you can switch it to the dynamic one:
    https://docs.generatepress.com/article/switching-to-dynamic-typography/

    2. You don’t need any PHP code to remove Google fonts, if there’s no Google fonts are selected at customizer > typography > fonts manager.

    3. In the customizer > typography > fonts manager, if you choose the ‘Open Sans’ font, make sure the Google fonts option is disabled.
    https://www.screencast.com/t/LHgnKGr7uNl

    4. Make sure you don’t choose the font in any individual GenerateBlocks block, otherwise the GB plugin would send request for Google fonts.

    #2385764
    Bettina

    Thank you Ying,

    Google fonts options is disabled and I didn’t found, where GenerateBlocks uses Google Fonts.
    I solved it with the Plugin “Disable and remove Google Fonts”
    But the Google Fonts are still visible in the Customizer. No Matter – the DSGVO-Problem ist solved.

    Dynamic typography is not avalable in GP-Premium 2.2.0

    Do I have to buy a new License for GP-Premium 3.2.0?
    Can’t find something about it.

    #2385805
    David
    Staff
    Customer Support

    Hi there,

    The free theme is version 3.2.0 – which requires no license.
    See here – it explains how to enable the dynamic typography:

    https://docs.generatepress.com/article/switching-to-dynamic-typography/

    #2387206
    Bettina

    Can I update my 2.2.0 GeneratePress-Premium Theme to 3.2.0 without loosing my layout and settings?

    3.2.0 Premium doesn’t exist? Then I loose my Premium-Tools when updating?
    Can’t find informations about this.

    #2387447
    David
    Staff
    Customer Support

    To cover there is the Theme and there is the Plugin. They are two separate things and they have different version numbers:

    GeneratePress Theme latest version is 3.2.0
    GeneratePress Premium Plugin latest version is 2.2.0

    You can update the Theme and the Plugin to the latest versions without losing your layout and settings.

    #2387497
    Bettina

    Ah, now I understand 🙂
    Many Thanks, David!

    Then I already have the Theme 3.2.0
    But NO Checkbox for “Use dynamic typography system”

    Furthermore I would like to erase the Google fonts from Font Manager in Customizer > Typography so that I can’t select any Google Font which isn’t local installed.
    Google Fonts and connecting to google server ist a very big problem here in Germany with DSGVO and I would like to make sure, that my customers don’t select a Google font with server connection.

    Is there any way to do this?

    The following Code didn’t work:
    add_action( ‘admin_init’, function() {
    add_filter( ‘generate_google_fonts_array’, ‘__return_empty_array’ );
    } );

    #2387605
    David
    Staff
    Customer Support

    OK, can i ask that you raise a new topic, as you will then have access to the Private Information field in the forum:

    https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information

    As if you agree i would like to log in to your site to see what the issue is.

    #2387613
    Bettina

    Ok – many thanks !!!

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