Skip to content

Commit 09459f1

Browse files
Media: improve error messages for unsupported uploads.
Improve language explaining the reason for failure when uploading a modern image format like WebP or AVIF that the server doesn’t handle. Props adamsilverstein, Cybr. Fixes #61361. git-svn-id: https://develop.svn.wordpress.org/trunk@59590 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 082f6e6 commit 09459f1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/wp-includes/script-loader.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -983,7 +983,7 @@ function wp_default_scripts( $scripts ) {
983983
/* translators: %s: File name. */
984984
'file_exceeds_size_limit' => __( '%s exceeds the maximum upload size for this site.' ),
985985
'zero_byte_file' => __( 'This file is empty. Please try another.' ),
986-
'invalid_filetype' => __( 'Sorry, you are not allowed to upload this file type.' ),
986+
'invalid_filetype' => __( 'This file cannot be processed by the web server.' ),
987987
'not_an_image' => __( 'This file is not an image. Please try another.' ),
988988
'image_memory_exceeded' => __( 'Memory exceeded. Please try another smaller file.' ),
989989
'image_dimensions_exceeded' => __( 'This is larger than the maximum size. Please try another.' ),
@@ -1007,7 +1007,7 @@ function wp_default_scripts( $scripts ) {
10071007
/* translators: %s: File name. */
10081008
'error_uploading' => __( '“%s” has failed to upload.' ),
10091009
'unsupported_image' => __( 'This image cannot be displayed in a web browser. For best results convert it to JPEG before uploading.' ),
1010-
'noneditable_image' => __( 'This image cannot be processed by the web server. Convert it to JPEG or PNG before uploading.' ),
1010+
'noneditable_image' => __( 'The web server cannot generate responsive image sizes for this image. Convert it to JPEG or PNG before uploading.' ),
10111011
'file_url_copied' => __( 'The file URL has been copied to your clipboard' ),
10121012
);
10131013

0 commit comments

Comments
 (0)