Un motore di ricerca WordPress per sviluppatori e autori di temi



upload_size_limit_filter ›

Da3.0.0
Deprecaton/a
upload_size_limit_filter ( $size )
Parametri:
  • (int) $size Upload size limit in bytes.
    Richiesto:
Ritorna:
  • (int) Upload size limit in bytes.
Definito a:
Codex:

Filters the maximum upload file size allowed, in bytes.



Sorgenti

function upload_size_limit_filter( $size ) {
	$fileupload_maxk = KB_IN_BYTES * get_site_option( 'fileupload_maxk', 1500 );
	if ( get_site_option( 'upload_space_check_disabled' ) ) {
		return min( $size, $fileupload_maxk );
	}

	return min( $size, $fileupload_maxk, get_upload_space_available() );
}