i have a directory which has more than 10 folders. i want to know the size of each folder . i did like this but i did not show any thing. i also tired other method in which i can get the size of specific folder .any suggestion ?
enter code here
$dir ="D:/WWebserver/Storage/" ;
function folderSize ($dir)
{
$size = 0;
foreach (glob(rtrim($dir, '/').'/*', GLOB_NOSORT) as $each) {
$size += is_file($each) ? filesize($each) : folderSize($each);
}
return $size;
echo $size ;
}