Determines the maximum upload size allowed in php.ini.
Source
/**
* Determines the maximum upload size allowed in php.ini.
*
* @since 2.5.0
*
* @return int Allowed upload size.
*/
function wp_max_upload_size() {
$u_bytes = wp_convert_hr_to_bytes( ini_get( 'upload_max_filesize' ) );
$p_bytes = wp_convert_hr_to_bytes( ini_get( 'post_max_size' ) );
/**
* Filters the maximum upload size allowed in php.ini.
*
* @since 2.5.0
Changelog
Version | Description |
---|---|
2.5.0 | Introduced. |
Get maximum upload size (in bytes)