wpmu_delete_blog_upload_dir filter-hookWP 3.0.0

Filters the upload base directory to delete when the site is deleted.

Usage

add_filter( 'wpmu_delete_blog_upload_dir', 'wp_kama_wpmu_delete_blog_upload_dir_filter', 10, 2 );

/**
 * Function for `wpmu_delete_blog_upload_dir` filter-hook.
 * 
 * @param string $basedir Uploads path without subdirectory. @see wp_upload_dir()
 * @param int    $site_id The site ID.
 *
 * @return string
 */
function wp_kama_wpmu_delete_blog_upload_dir_filter( $basedir, $site_id ){

	// filter...
	return $basedir;
}
$basedir(string)
Uploads path without subdirectory. @see wp_upload_dir()
$site_id(int)
The site ID.

Changelog

Since 3.0.0 Introduced.

Where the hook is called

wp_uninitialize_site()
wpmu_delete_blog_upload_dir
wp-includes/ms-site.php 828
$dir     = apply_filters( 'wpmu_delete_blog_upload_dir', $uploads['basedir'], $site->id );

Where the hook is used in WordPress

Usage not found.