コード例 #1
0
ファイル: DokumenSiswa.php プロジェクト: alisyihab/sisdik
 /**
  * @param  string $type
  * @return string
  */
 public function getFilesizeNamaFileDisk($type = 'KB')
 {
     try {
         $file = new File($this->getRelativePathNamaFileDisk());
     } catch (FileNotFoundException $err) {
         return '? ' . $type;
     }
     if ($file) {
         return FileSizeFormatter::formatBytes($file->getSize(), $type);
     }
 }
コード例 #2
0
ファイル: Siswa.php プロジェクト: alisyihab/sisdik
 /**
  * @param  string $type
  * @return string
  */
 public function getFilesizeFotoDisk($type = 'KB')
 {
     $file = new File($this->getRelativePathFotoDisk());
     return FileSizeFormatter::formatBytes($file->getSize(), $type);
 }