changed formatFilesize algorithm, added pow function

for the formatFilesize you could also use a counter instead of
isset($units[1])