WordPress.org

Make WordPress Core

Opened 8 months ago

Last modified 2 weeks ago

#47656 new enhancement

Remove 'Error:' prefixes from error notices as they're redundant

Reported by: garrett-eclipse Owned by:
Milestone: 5.5 Priority: normal
Severity: normal Version:
Component: I18N Keywords:
Focuses: ui, accessibility, administration, ui-copy Cc:

Description

Branching from #47003

@ramiy's comment - https://core.trac.wordpress.org/ticket/47003#comment:10

I think that this ticket should handled only the merge of similar translation strings. A separate ticket should remove the Error: prefix from the error messages in the dashboard.

The Add New user form throws errors when invalid characters are used, etc. These have an Error: prefix on them which is unneeded and makes it harder to reuse some of the strings as found in #47003.

I would suggest they simply be removed.

Change History (10)

#1 follow-up: @SergeyBiryukov
8 months ago

Previous discussion: #15887, which resulted in [18841].

Specifically, I think comment:5:ticket:15887 sums up the purpose of the ERROR: prefix nicely:

All CAPITAL letters in a word typically denotes Emphasis. It's not meant to be

"Good day gentle, but incorrect, user - there seems to be an error. Be a sport and type in your e-mail address"

But rather

"HEY, USER! (yelling) THERE'S A PROBLEM! ATTENTION! ERROR. Type in your email address please"

Last edited 3 weeks ago by SergeyBiryukov (previous) (diff)

#2 @SergeyBiryukov
8 months ago

We could, however, move the ERROR: prefix out of the strings and add it separately, see the error message in wp-admin/themes.php for example. Related: #38860

Last edited 8 months ago by SergeyBiryukov (previous) (diff)

#3 in reply to: ↑ 1 @garrett-eclipse
5 months ago

  • Milestone changed from Awaiting Review to 5.4

Thanks @SergeyBiryukov I agree completely and feel isolating the prefix is our best option. I've updated #47003 with that information and am moving this into 5.4 so the two can coincide.

#4 @afercia
4 months ago

#48412 was marked as a duplicate.

#5 @afercia
4 months ago

  • Focuses ui accessibility ui-copy added

Quoting the description from the duplicate #48412. I'd also suggest to change the component to "Administration" as this is also related to UI and accessibility and not only to i18n.

Follow up to ticket:43037#comment:42

On #43037, some error messages for the login screen were improved and, amongst other things, the all caps word ERROR was removed..

There are other occurrences in core of the all caps ERROR included in error messages, and sentence case Error as well.

I'd like to propose to remove all of them: all caps should be avoided for better readability and because screen readers may pronounce all caps words as abbreviations.

Also: sometimes ERROR is all caps, sometimes it's sentence case, sometimes it's bold, sometimes the entire error message is bold. The most recently added ones (PHP compatibility and SIte Health) seem to use sentence case. Some consistency would be nice.

A few examples:

<strong>ERROR:</strong> There was an error connecting to the server ...
<strong>Error:</strong> Current WordPress and PHP versions do not meet ...
<strong>Error:</strong> This plugin <strong>requires a newer version of PHP</strong>.
<strong>' . __( 'ERROR: The network could not be created.' ) . '</strong>

These messages appear in admin notices that are already marked as errors because of the red border. Moreover, I'm not sure there's the need to specify "error" at the beginning of the message, as that's not relevant for users. Instead, it's the content of the message that is relevant. For example:

ERROR: There was an error connecting to the server, Please verify the settings are correct.

Admittedly, this is the more evident case as the word "error" is repeated also in the second part of the message. (note: the comma should be changed to a period)

Also in other cases "Error" could be just removed. For example:

Error: Current WordPress and PHP versions do not meet minimum requirements for {plugin name here}

As a user, I'm not interested whether this is an error, a warning, an informational message or whatever :) I'm just interested in the content of the message which is already made prominent by the notice styling.

This ticket was mentioned in Slack in #accessibility by afercia. View the logs.


3 weeks ago

#8 follow-up: @sabernhardt
3 weeks ago

After discussion in accessibility bug scrub, we agreed to focus on the easy part (replacing all-caps) for 5.4 and then try to make a bigger change to messaging (very) early in the 5.5 cycle.

This quick fix portion could be handled on ticket #42945:
Search for uppercase ERROR: and replace with Error:

#9 @SergeyBiryukov
3 weeks ago

In 47156:

Accessibility: Text Changes: Use sentence case for the word Error in various error messages, instead of all caps.

Using all caps should be avoided for better readability and because screen readers may pronounce all-caps words as abbreviations.

Props afercia, ryokuhi, sabernhardt, garrett-eclipse.
See #47656, #43037, #42945.

#10 in reply to: ↑ 8 @SergeyBiryukov
2 weeks ago

  • Milestone changed from 5.4 to 5.5

Replying to sabernhardt:

After discussion in accessibility bug scrub, we agreed to focus on the easy part (replacing all-caps) for 5.4 and then try to make a bigger change to messaging (very) early in the 5.5 cycle.

Replacing all-caps was addressed in [47156], moving to 5.5 for any follow-up changes.

Note: See TracTickets for help on using tickets.