function wp_max_upload_size() {}

Defined filters

  • upload_size_limit
    apply_filters( 'upload_size_limit', min($u_bytes, $p_bytes)

Source code

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' ) );

	$bytes = apply_filters( 'upload_size_limit', min($u_bytes, $p_bytes), $u_bytes, $p_bytes );

	return $bytes;



No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: