WordPress.org

Make WordPress Core

Ticket #37171: patch_37171.diff

File patch_37171.diff, 4.3 KB (added by leobaiano, 3 years ago)

Adds preconnect to google fonts in themes

  • wp-content/themes/twentyeleven/header.php

     
    4343                echo esc_html( ' | ' . sprintf( __( 'Page %s', 'twentyeleven' ), max( $paged, $page ) ) );
    4444
    4545        ?></title>
     46
     47<!-- Add preconnect to Google fonts -->
     48<link href='https://fonts.gstatic.com' rel='preconnect' crossorigin>
     49
    4650<link rel="profile" href="http://gmpg.org/xfn/11" />
    4751<link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" />
    4852<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
  • wp-content/themes/twentyfifteen/header.php

     
    1212<html <?php language_attributes(); ?> class="no-js">
    1313<head>
    1414        <meta charset="<?php bloginfo( 'charset' ); ?>">
     15
     16        <!-- Add preconnect to Google fonts -->
     17        <link href='https://fonts.gstatic.com' rel='preconnect' crossorigin>
     18
    1519        <meta name="viewport" content="width=device-width">
    1620        <link rel="profile" href="http://gmpg.org/xfn/11">
    1721        <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
    1822        <!--[if lt IE 9]>
    1923        <script src="<?php echo esc_url( get_template_directory_uri() ); ?>/js/html5.js"></script>
    2024        <![endif]-->
     25       
    2126        <?php wp_head(); ?>
    2227</head>
    2328
  • wp-content/themes/twentyfourteen/header.php

     
    2222        <meta charset="<?php bloginfo( 'charset' ); ?>">
    2323        <meta name="viewport" content="width=device-width">
    2424        <title><?php wp_title( '|', true, 'right' ); ?></title>
     25       
     26        <!-- Add preconnect to Google fonts -->
     27        <link href='https://fonts.gstatic.com' rel='preconnect' crossorigin>
     28
    2529        <link rel="profile" href="http://gmpg.org/xfn/11">
    2630        <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
    2731        <!--[if lt IE 9]>
  • wp-content/themes/twentyten/header.php

     
    3333                echo esc_html( ' | ' . sprintf( __( 'Page %s', 'twentyten' ), max( $paged, $page ) ) );
    3434
    3535        ?></title>
     36
     37<!-- Add preconnect to Google fonts -->
     38<link href='https://fonts.gstatic.com' rel='preconnect' crossorigin>
     39
    3640<link rel="profile" href="http://gmpg.org/xfn/11" />
    3741<link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" />
    3842<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
  • wp-content/themes/twentythirteen/header.php

     
    2222        <meta charset="<?php bloginfo( 'charset' ); ?>">
    2323        <meta name="viewport" content="width=device-width">
    2424        <title><?php wp_title( '|', true, 'right' ); ?></title>
     25
     26        <!-- Add preconnect to Google fonts -->
     27        <link href='https://fonts.gstatic.com' rel='preconnect' crossorigin>
     28
    2529        <link rel="profile" href="http://gmpg.org/xfn/11">
    2630        <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
    2731        <!--[if lt IE 9]>
  • wp-content/themes/twentytwelve/header.php

     
    2222<meta charset="<?php bloginfo( 'charset' ); ?>" />
    2323<meta name="viewport" content="width=device-width" />
    2424<title><?php wp_title( '|', true, 'right' ); ?></title>
     25
     26<!-- Add preconnect to Google fonts -->
     27<link href='https://fonts.gstatic.com' rel='preconnect' crossorigin>
     28
    2529<link rel="profile" href="http://gmpg.org/xfn/11" />
    2630<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
    2731<?php // Loads HTML5 JavaScript file to add support for HTML5 elements in older IE versions. ?>