recurse_dirsize


recurse_dirsize ( $directory, $exclude = null, $max_execution_time = null )

Parameters:
  • (string) $directory Full path of a directory.
  • (string|array) $exclude Optional. Full path of a subdirectory to exclude from the total, or array of paths. Expected without trailing slash(es).
  • (int) $max_execution_time Maximum time to run before giving up. In seconds. The timeout is global and is measured from the moment WordPress started to load.
Returns:
  • (int|false|null) Size in bytes if a valid directory. False if not. Null if timeout.
Defined at:
Change Log:
  • 5: .
  • M: U

Description

Get the size of a directory recursively.

Used by get_dirsize() to get a directory's size when it contains other directories.

Related Functions

get_dirsize, remove_image_size, rest_parse_date, image_resize, get_current_site

Top Google Results

User discussions

wpseek mobile