Massive thanks to @Joseinnewworld for adding another 22 #NFTs to his collection! 🙌 Our collection is now almost sold out — what a journey! From here on, I’ll be shifting my focus more on developing the system rather than producing new #NFT. Exciting times ahead 🚀 #eCash $XEC pic.twitter.com/O7dQlr0OtG
— NFToa (@nftoa_) October 8, 2025
Once, I was building a website focused on file management, where it needed to read the size of folders and subfolders. Here's a legacy function that accomplishes that:
<?php
function folderSize($dir)
{
$size = 0;
foreach (glob(rtrim($dir, '/') . '/*', GLOB_NOSORT) as $each) {
$size += is_file($each) ? filesize($each) : folderSize($each);
}
return $size;
}
At least on Linux, this won't include dot files (since * doesn't match .some-file). Additionally, on my machine, empty directories still occupy some space (4096 bytes according to du), which is also not included in folderSize. Oh, and thanks—I’m using something quite similar.
