Make WordPress Core

Ticket #56532: 56532-38.diff

File 56532-38.diff, 3.1 KB (added by peterwilsoncc, 2 years ago)
  • src/wp-admin/css/colors.css

    diff --git a/src/wp-admin/css/colors.css b/src/wp-admin/css/colors.css
    index 6eafbf27a9..196d7f3c59 100644
    a b div.updated, 
    606606        box-shadow:         0px 1px 1px 0px rgba(0,0,0,0.1);
    607607}
    608608
     609.update-nag-core-insecure {
     610        color: #fff;
     611        background-color: #ac1b1b;
     612        border-left-color: #cd5a5a;
     613}
     614
     615.update-nag-core-insecure a {
     616        color: #fff;
     617}
     618
    609619div.error,
    610620.login #login_error {
    611621        background: #fff;
  • src/wp-admin/css/wp-admin.css

    diff --git a/src/wp-admin/css/wp-admin.css b/src/wp-admin/css/wp-admin.css
    index 7ae4d6c638..bfdd63fc51 100644
    a b th.action-links { 
    14521452        margin: 25px 20px 0 2px;
    14531453}
    14541454
     1455.update-nag-core-insecure {
     1456        font-weight: bold;
     1457}
     1458
     1459.update-nag-core-insecure > p:first-child {
     1460        margin-top: 0;
     1461}
     1462
     1463.update-nag-core-insecure > p:last-child {
     1464        margin-bottom: 0;
     1465}
     1466
     1467.update-nag-core-insecure a {
     1468        text-decoration: underline;
     1469}
     1470
    14551471.plugins .plugin-update {
    14561472        padding: 0;
    14571473}
  • src/wp-admin/includes/update.php

    diff --git a/src/wp-admin/includes/update.php b/src/wp-admin/includes/update.php
    index c514d208e5..b7071e4b8d 100644
    a b function update_nag() { 
    210210                return false;
    211211
    212212        if ( current_user_can('update_core') ) {
    213                 $msg = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! <a href="%2$s">Please update now</a>.'), $cur->current, network_admin_url( 'update-core.php' ) );
     213                $msg       = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! <a href="%2$s">Please update now</a>.'), $cur->current, network_admin_url( 'update-core.php' ) );
     214                $msg_line2 = sprintf(
     215                        /* translators: 1: WordPress version number, 2: Link to update WordPress */
     216                        __( 'Important! Your version of WordPress (%1$s) is no longer supported, you will not receive any security updates for your website. To keep your site secure, please <a href="%2$s">update to the latest version of WordPress</a>.' ),
     217                        get_bloginfo( 'version', 'display' ),
     218                        network_admin_url( 'update-core.php' )
     219                );
    214220        } else {
    215                 $msg = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! Please notify the site administrator.'), $cur->current );
     221                $msg       = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! Please notify the site administrator.'), $cur->current );
     222                $msg_line2 = sprintf(
     223                        /* translators: 1: WordPress version number, 2: Link to update WordPress */
     224                        __( 'Important! Your version of WordPress (%1$s) is no longer supported, you will not receive any security updates for your website. To keep your site secure, please <a href="%2$s">update to the latest version of WordPress</a>.' ),
     225                        get_bloginfo( 'version', 'display' ),
     226                        'https://wordpress.org/download/'
     227                );
    216228        }
    217         echo "<div class='update-nag'>$msg</div>";
     229        echo "<div class='update-nag update-nag-core-insecure'><p>$msg</p><p>$msg_line2</p></div>";
    218230}
    219231add_action( 'admin_notices', 'update_nag', 3 );
    220232add_action( 'network_admin_notices', 'update_nag', 3 );