芝麻web文件管理V1.00
编辑当前文件:/home/qrafawbu/kwesioben.com/paymoney/app/helpers/strings.php
0, 'K' => 1, 'M' => 2, 'G' => 3, 'T' => 4, 'P' => 5]; $value = 0; if ($bytes > 0) { if (!array_key_exists($unit, $units)) { $pow = floor(log($bytes) / log(1024)); $unit = array_search($pow, $units); } $value = ($bytes / pow(1024, floor($units[$unit]))); } return sprintf('%d' . $unit, $value); } }