WordPress.org

Make WordPress Core

Ticket #43717: 43717.diff

File 43717.diff, 5.6 KB (added by soulseekah, 3 years ago)

esc_url on bloginfo pingback URL

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

    diff --git a/src/wp-content/themes/twentyeleven/header.php b/src/wp-content/themes/twentyeleven/header.php
    index df8f7ee..b3ef310 100644
    a b if ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) { 
    4949        </title>
    5050<link rel="profile" href="http://gmpg.org/xfn/11" />
    5151<link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" />
    52 <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
     52<link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    5353<!--[if lt IE 9]>
    5454<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
    5555<![endif]-->
  • src/wp-content/themes/twentyfifteen/header.php

    diff --git a/src/wp-content/themes/twentyfifteen/header.php b/src/wp-content/themes/twentyfifteen/header.php
    index a088d85..d0aff73 100644
    a b  
    1414        <meta charset="<?php bloginfo( 'charset' ); ?>">
    1515        <meta name="viewport" content="width=device-width">
    1616        <link rel="profile" href="http://gmpg.org/xfn/11">
    17         <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
     17        <link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    1818        <!--[if lt IE 9]>
    1919        <script src="<?php echo esc_url( get_template_directory_uri() ); ?>/js/html5.js"></script>
    2020        <![endif]-->
  • src/wp-content/themes/twentyfourteen/header.php

    diff --git a/src/wp-content/themes/twentyfourteen/header.php b/src/wp-content/themes/twentyfourteen/header.php
    index 4dec164..43e861c 100644
    a b  
    2323        <meta name="viewport" content="width=device-width">
    2424        <title><?php wp_title( '|', true, 'right' ); ?></title>
    2525        <link rel="profile" href="http://gmpg.org/xfn/11">
    26         <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
     26        <link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    2727        <!--[if lt IE 9]>
    2828        <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js"></script>
    2929        <![endif]-->
  • src/wp-content/themes/twentyseventeen/functions.php

    diff --git a/src/wp-content/themes/twentyseventeen/functions.php b/src/wp-content/themes/twentyseventeen/functions.php
    index 2e147a9..543da5c 100644
    a b add_action( 'wp_head', 'twentyseventeen_javascript_detection', 0 ); 
    398398 */
    399399function twentyseventeen_pingback_header() {
    400400        if ( is_singular() && pings_open() ) {
    401                 printf( '<link rel="pingback" href="%s">' . "\n", get_bloginfo( 'pingback_url' ) );
     401                printf( '<link rel="pingback" href="%s">' . "\n", esc_url( get_bloginfo( 'pingback_url' ) ) );
    402402        }
    403403}
    404404add_action( 'wp_head', 'twentyseventeen_pingback_header' );
  • src/wp-content/themes/twentysixteen/header.php

    diff --git a/src/wp-content/themes/twentysixteen/header.php b/src/wp-content/themes/twentysixteen/header.php
    index 9bc0d3e..b2d1cbb 100644
    a b  
    1616        <meta name="viewport" content="width=device-width, initial-scale=1">
    1717        <link rel="profile" href="http://gmpg.org/xfn/11">
    1818        <?php if ( is_singular() && pings_open( get_queried_object() ) ) : ?>
    19         <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
     19        <link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    2020        <?php endif; ?>
    2121        <?php wp_head(); ?>
    2222</head>
  • src/wp-content/themes/twentyten/header.php

    diff --git a/src/wp-content/themes/twentyten/header.php b/src/wp-content/themes/twentyten/header.php
    index 6c2ee4c..8afe43b 100644
    a b if ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) { 
    3939        </title>
    4040<link rel="profile" href="http://gmpg.org/xfn/11" />
    4141<link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" />
    42 <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
     42<link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    4343<?php
    4444        /*
    4545         * We add some JavaScript to pages with the comment form
  • src/wp-content/themes/twentythirteen/header.php

    diff --git a/src/wp-content/themes/twentythirteen/header.php b/src/wp-content/themes/twentythirteen/header.php
    index 6253472..2495844 100644
    a b  
    2323        <meta name="viewport" content="width=device-width">
    2424        <title><?php wp_title( '|', true, 'right' ); ?></title>
    2525        <link rel="profile" href="http://gmpg.org/xfn/11">
    26         <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
     26        <link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    2727        <!--[if lt IE 9]>
    2828        <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js"></script>
    2929        <![endif]-->
  • src/wp-content/themes/twentytwelve/header.php

    diff --git a/src/wp-content/themes/twentytwelve/header.php b/src/wp-content/themes/twentytwelve/header.php
    index 2b95b49..9e9c85d 100644
    a b  
    2323<meta name="viewport" content="width=device-width" />
    2424<title><?php wp_title( '|', true, 'right' ); ?></title>
    2525<link rel="profile" href="http://gmpg.org/xfn/11" />
    26 <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
     26<link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
    2727<?php // Loads HTML5 JavaScript file to add support for HTML5 elements in older IE versions. ?>
    2828<!--[if lt IE 9]>
    2929<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>