WordPress.org

Make WordPress Core


Ignore:
Timestamp:
10/19/2020 11:37:53 PM (12 months ago)
Author:
SergeyBiryukov
Message:

General: Remove noreferrer from wp_targeted_link_rel() and other uses.

When noopener noreferrer was originally added in #37941 and related tickets, the noreferrer bit was specifically included due to Firefox not supporting noopener at the time.

Since noopener has been supported by all major browsers for a while, it should now be safe to remove the noreferrer attribute from core.

Props Mista-Flo, audrasjb, joostdevalk, jonoaldersonwp, peterwilsoncc, elgameel.
Fixes #49558.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-site-health.php

    r49193 r49215  
    731731            ),
    732732            'actions'     => sprintf(
    733                 '<p><a href="%s" target="_blank" rel="noopener noreferrer">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
     733                '<p><a href="%s" target="_blank" rel="noopener">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
    734734                esc_url( wp_get_update_php_url() ),
    735735                __( 'Learn more about updating PHP' ),
     
    843843                    /* translators: Localized team handbook, if one exists. */
    844844                    esc_url( __( 'https://make.wordpress.org/hosting/handbook/handbook/server-environment/#php-extensions' ) ),
    845                     'target="_blank" rel="noopener noreferrer"',
     845                    'target="_blank" rel="noopener"',
    846846                    sprintf(
    847847                        ' <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span>',
     
    11601160            ),
    11611161            'actions'     => sprintf(
    1162                 '<p><a href="%s" target="_blank" rel="noopener noreferrer">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
     1162                '<p><a href="%s" target="_blank" rel="noopener">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
    11631163                /* translators: Localized version of WordPress requirements if one exists. */
    11641164                esc_url( __( 'https://wordpress.org/about/requirements/' ) ),
     
    13971397
    13981398            $result['actions'] = sprintf(
    1399                 '<p><a href="%s" target="_blank" rel="noopener noreferrer">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
     1399                '<p><a href="%s" target="_blank" rel="noopener">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
    14001400                /* translators: Localized Support reference. */
    14011401                esc_url( __( 'https://wordpress.org/support' ) ),
     
    14351435            ),
    14361436            'actions'     => sprintf(
    1437                 '<p><a href="%s" target="_blank" rel="noopener noreferrer">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
     1437                '<p><a href="%s" target="_blank" rel="noopener">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
    14381438                /* translators: Documentation explaining debugging in WordPress. */
    14391439                esc_url( __( 'https://wordpress.org/support/article/debugging-in-wordpress/' ) ),
     
    15041504            ),
    15051505            'actions'     => sprintf(
    1506                 '<p><a href="%s" target="_blank" rel="noopener noreferrer">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
     1506                '<p><a href="%s" target="_blank" rel="noopener">%s <span class="screen-reader-text">%s</span><span aria-hidden="true" class="dashicons dashicons-external"></span></a></p>',
    15071507                /* translators: Documentation explaining HTTPS and why it should be used. */
    15081508                esc_url( __( 'https://wordpress.org/support/article/why-should-i-use-https/' ) ),
Note: See TracChangeset for help on using the changeset viewer.