Make WordPress Core


Ignore:
Timestamp:
02/08/2025 03:51:03 PM (4 months ago)
Author:
audrasjb
Message:

Administration: Error messages improvements in WP Admin.

This changeset improves a bunch of WP-Admin error messages, notably replacing the good old cryptic "Something went wrong" message with more helpful information.

Props peterwilsoncc, netweb, karmatosed, JoshuaWold, mrtortai, audrasjb, sukhendu2002, joedolson.
See #43622.

File:
1 edited

Legend:

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

    r59784 r59789  
    2525        if ( ! $theme->exists() || ! $theme->is_allowed() ) {
    2626            wp_die(
    27                 '<h1>' . __( 'Something went wrong.' ) . '</h1>' .
     27                '<h1>' . __( 'An error occurred.' ) . '</h1>' .
    2828                '<p>' . __( 'The requested theme does not exist.' ) . '</p>',
    2929                403
     
    6868        if ( ! $theme->exists() ) {
    6969            wp_die(
    70                 '<h1>' . __( 'Something went wrong.' ) . '</h1>' .
     70                '<h1>' . __( 'An error occurred while deleting the theme.' ) . '</h1>' .
    7171                '<p>' . __( 'The requested theme does not exist.' ) . '</p>',
    7272                403
Note: See TracChangeset for help on using the changeset viewer.