for a filemanagement i calculate the size of each file and the directories in a specific folder. I calculate the size of the files like below:
sizeFormat(filesize($dir . '/' . $file))
and the size of the directories (included subdirs) like below:
sizeFormat(recursive_directory_size($dir . '/' . $file))
How can i calculate now the sum size of all files and directories in that specific folder?