wp_filesize хук-фильтрWP 6.0.0

Filters the size of the file.

Использование

add_filter( 'wp_filesize', 'wp_kama_filesize_filter', 10, 2 );

/**
 * Function for `wp_filesize` filter-hook.
 * 
 * @param int    $size The result of PHP filesize on the file.
 * @param string $path Path to the file.
 *
 * @return int
 */
function wp_kama_filesize_filter( $size, $path ){

	// filter...
	return $size;
}
$size(int)
The result of PHP filesize on the file.
$path(строка)
Path to the file.

Список изменений

С версии 6.0.0 Введена.

Где вызывается хук

wp_filesize()
wp_filesize
wp-includes/functions.php 3582
return (int) apply_filters( 'wp_filesize', $size, $path );

Где используется хук в WordPress

Использование не найдено.