Support » Plugin: Remove Google Fonts References » It works, but there’s maybe one omission?

  • Unlike the Disable Google Fonts plugin, this one worked almost perfectly for me. (I’m using the econature theme from cmsmasters.)

    The result was that my fonts still look the same as before and the links to fonts.googleapis.com no longer appear in my html code.

    However, I noticed that this link remained in my html:
    <link rel='dns-prefetch' href='//fonts.googleapis.com' />

    To get rid of that, I just added this to my functions.php file:

    /*
     * Remove these lines from our html:
     * <link rel='dns-prefetch' href='//fonts.googleapis.com' />
     * <link rel='dns-prefetch' href='//s.w.org' />
     */
    remove_action( 'wp_head', 'wp_resource_hints', 2 );

    NB – This also removed this code from my html:
    <link rel='dns-prefetch' href='//s.w.org' />

  • The topic ‘It works, but there’s maybe one omission?’ is closed to new replies.