Make WordPress Core


Ignore:
Timestamp:
04/26/2018 02:30:24 PM (8 years ago)
Author:
flixos90
Message:

General: Implement editorial, design and accessibility feedback for the PHP version nag.

The updated version of the nag is shorter, more on point and less aggressive than the previous one. It integrates better with the other dashboard widgets and fixes several accessibility concerns. A yellow warning color is used when the current PHP version is outdated, a red error color is used when it is also insecure.

Props afercia, birgire, danieltj, flixos90, johnjamesjacoby, karmatosed, Luciano Croce, nerrad, pento, schlessera, SergeyBiryukov, sonjaleix.

Fixes #41191.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/template.php

    r42974 r43006  
    11411141                                                echo '</button>';
    11421142                                        }
    1143                                         echo "<h2 class='hndle'><span>{$box['title']}</span></h2>\n";
     1143                                        echo '<h2 class="hndle">';
     1144                                        if ( 'dashboard_php_nag' === $box['id'] ) {
     1145                                                echo '<span aria-hidden="true" class="dashicons dashicons-warning"></span>';
     1146                                                echo '<span class="screen-reader-text">' . __( 'Warning:' ) . ' </span>';
     1147                                        }
     1148                                        echo "<span>{$box['title']}</span>";
     1149                                        echo "</h2>\n";
    11441150                                        echo '<div class="inside">' . "\n";
    11451151                                        call_user_func( $box['callback'], $object, $box );
    … …  
    21672173<!DOCTYPE html>
    21682174<!--[if IE 8]>
    2169 <html xmlns="http://www.w3.org/1999/xhtml" class="ie8 <?php echo $admin_html_class; ?>" 
     2175<html xmlns="http://www.w3.org/1999/xhtml" class="ie8 <?php echo $admin_html_class; ?>"
    21702176                                                                                                                                        <?php
    21712177                                                                                                                                        /**
    … …  
    21792185<![endif]-->
    21802186<!--[if !(IE 8) ]><!-->
    2181 <html xmlns="http://www.w3.org/1999/xhtml" class="<?php echo $admin_html_class; ?>" 
     2187<html xmlns="http://www.w3.org/1999/xhtml" class="<?php echo $admin_html_class; ?>"
    21822188                                                                                                                                <?php
    21832189                                                                                                                                /** This action is documented in wp-admin/includes/template.php */
Note: See TracChangeset for help on using the changeset viewer.