system/modules/DocumentManagementSystem/classes/pojos/Document.php
public static function formatFileSize($doubleFileSize, $strUnit)
	{
		$value = number_format($doubleFileSize, 2, $GLOBALS['TL_LANG']['DMS']['file_size_format']['dec_point'], $GLOBALS['TL_LANG']['DMS']['file_size_format']['$thousands_sep']);
		if (substr($value, -3) == ($GLOBALS['TL_LANG']['DMS']['file_size_format']['dec_point'] . "00"))
		{
			$value = substr($value, 0, - 3);
		}
		return sprintf($GLOBALS['TL_LANG']['DMS']['file_size_format']['text'], $value, $GLOBALS['TL_LANG']['DMS']['file_size_unit'][$strUnit]);
	}
public static function formatFileSize($doubleFileSize, $strUnit)
	{
		$value = number_format($doubleFileSize, 2, $GLOBALS['TL_LANG']['DMS']['file_size_format']['dec_point'], $GLOBALS['TL_LANG']['DMS']['file_size_format']['$thousands_sep']);
		if (substr($value, -3) == ($GLOBALS['TL_LANG']['DMS']['file_size_format']['dec_point'] . "00"))
		{
			$value = substr($value, 0, - 3);
		}
		return sprintf($GLOBALS['TL_LANG']['DMS']['file_size_format']['text'], $value, $GLOBALS['TL_LANG']['DMS']['file_size_unit'][$strUnit]);
	}
public static function formatFileSize ( $ doubleFileSize , $ strUnit ) { $ value = number_format ( $ doubleFileSize , 2 , $ GLOBALS [ 'TL_LANG' ] [ 'DMS' ] [ 'file_size_format' ] [ 'dec_point' ] , $ GLOBALS [ 'TL_LANG' ] [ 'DMS' ] [ 'file_size_format' ] [ '$thousands_sep' ] ) ; if ( substr ( $ value , - 3 ) == ( $ GLOBALS [ 'TL_LANG' ] [ 'DMS' ] [ 'file_size_format' ] [ 'dec_point' ] . "00" ) ) { $ value = substr ( $ value , 0 , - 3 ) ; } return sprintf ( $ GLOBALS [ 'TL_LANG' ] [ 'DMS' ] [ 'file_size_format' ] [ 'text' ] , $ value , $ GLOBALS [ 'TL_LANG' ] [ 'DMS' ] [ 'file_size_unit' ] [ $ strUnit ] ) ; }
Utility function to format file size values

@param	double	$doubleFileSize	The file size value.
@param	string	$strUnit	The file size unit.
@return	string	The formatted file size value.
Utility function to format file size values