Making WordPress.org


Ignore:
Timestamp:
04/29/2017 02:16:17 PM (9 years ago)
Author:
ocean90
Message:

Theme Directory: Use the new library loader for Google Charts.

Prevents a warning in Chrome about the use of document.write, see https://www.chromestatus.com/feature/5718547946799104.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes/functions.php

    r3623 r5425  
    4848
    4949    if ( ! is_singular( 'page' ) ) {
    50         wp_enqueue_script( 'google-jsapi', '//www.google.com/jsapi', array( 'jquery' ), null, true );
     50        wp_enqueue_script( 'google-charts-loader', 'https://www.gstatic.com/charts/loader.js', array( 'jquery' ), null, true );
    5151        wp_enqueue_script( 'wporg-theme', get_template_directory_uri() . "/js/theme{$suffix}.js", array( 'wp-backbone' ), 10, true );
    5252
Note: See TracChangeset for help on using the changeset viewer.