I18N: Replace `php.ini`, `post_max_size`, and `upload_max_filesize` with placeholders in "File is empty" error message.
Props ramiy. Fixes #48868. Built from https://develop.svn.wordpress.org/trunk@47043 git-svn-id: http://core.svn.wordpress.org/trunk@46843 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
918dead27e
commit
667f26b3af
|
@ -804,7 +804,13 @@ function _wp_handle_upload( &$file, $overrides, $time, $action ) {
|
|||
if ( is_multisite() ) {
|
||||
$error_msg = __( 'File is empty. Please upload something more substantial.' );
|
||||
} else {
|
||||
$error_msg = __( 'File is empty. Please upload something more substantial. This error could also be caused by uploads being disabled in your php.ini or by post_max_size being defined as smaller than upload_max_filesize in php.ini.' );
|
||||
$error_msg = sprintf(
|
||||
/* translators: 1: php.ini, 2: post_max_size, 3: upload_max_filesize */
|
||||
__( 'File is empty. Please upload something more substantial. This error could also be caused by uploads being disabled in your %1$s file or by %2$s being defined as smaller than %3$s in %1$s.' ),
|
||||
'php.ini',
|
||||
'post_max_size',
|
||||
'upload_max_filesize'
|
||||
);
|
||||
}
|
||||
return call_user_func_array( $upload_error_handler, array( &$file, $error_msg ) );
|
||||
}
|
||||
|
|
|
@ -82,7 +82,13 @@ function wp_import_cleanup( $id ) {
|
|||
function wp_import_handle_upload() {
|
||||
if ( ! isset( $_FILES['import'] ) ) {
|
||||
return array(
|
||||
'error' => __( 'File is empty. Please upload something more substantial. This error could also be caused by uploads being disabled in your php.ini or by post_max_size being defined as smaller than upload_max_filesize in php.ini.' ),
|
||||
'error' => sprintf(
|
||||
/* translators: 1: php.ini, 2: post_max_size, 3: upload_max_filesize */
|
||||
__( 'File is empty. Please upload something more substantial. This error could also be caused by uploads being disabled in your %1$s file or by %2$s being defined as smaller than %3$s in %1$s.' ),
|
||||
'php.ini',
|
||||
'post_max_size',
|
||||
'upload_max_filesize'
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.4-alpha-47042';
|
||||
$wp_version = '5.4-alpha-47043';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue