Make WordPress Core


Ignore:
Timestamp:
03/10/2025 06:14:48 PM (2 months ago)
Author:
joedolson
Message:

Administration: Update out of date error message styling.

Change several error message across core to use WordPress standard styling. Ensure only prefixes are wrapped in strong tags rather than the whole message, use notice notice-error classes where appropriate, and replace a custom error with wp_admin_notice() in multisite.

Props afercia, rajinsharwar, robinmartijn, mukesh27, sabernhardt, oglekler, joedolson, chaion07, im3dabasia1, audrasjb, dkarfa, najmulsaju.
Fixes #50402.

File:
1 edited

Legend:

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

    r59789 r59960  
    346346if ( $current_theme->errors() && ( ! is_multisite() || current_user_can( 'manage_network_themes' ) ) ) {
    347347    wp_admin_notice(
    348         __( 'Error:' ) . ' ' . $current_theme->errors()->get_error_message(),
     348        '<strong>' . __( 'Error:' ) . '</strong> ' . $current_theme->errors()->get_error_message(),
    349349        array(
    350350            'additional_classes' => array( 'error' ),
Note: See TracChangeset for help on using the changeset viewer.