is_upload_space_available() WordPress Function

The is_upload_space_available() function checks if there is enough space left on the server to upload a new file. This is useful for preventing users from uploading large files when the server is running out of space.

is_upload_space_available() #

Determines if there is any upload space left in the current blog’s quota.


Return

(bool) True if space is available, false otherwise.


Top ↑

Source

File: wp-includes/ms-functions.php

function is_upload_space_available() {
	if ( get_site_option( 'upload_space_check_disabled' ) ) {
		return true;
	}

	return (bool) get_upload_space_available();
}


Top ↑

Changelog

Changelog
VersionDescription
3.0.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More
Show More