function ByteSize($bytes)
{
$size = $bytes / 1024;
if($size < 1024)
{
$size = number_format($size, 2);
$size .= ' KB';
}else {
if($size / 1024 < 1024) {
$size = number_format($size / 1024, 2);
$size .= ' MB';
} else if($size / 1024 / 1024 < 1024) {
$size = number_format($size / 1024 / 1024, 2);
$size .= ' GB';
}
}
return $size;
}
[Friday, January 11, 2008
|
1 comments
]
Popular Posts
- Creating Custom Module in VtigerCRM
- Help with codeignitor
- Contact Me
- Add/Remove text control using javascript
- Creating Google map and adding markers ans polyline on it
- Function to check and prefix http on url [modified].
- function to check whether the year given is a leap year or not
- Running a perl script from PHP
- Random password generation :using ajax and jquery
- How to find out the Mysql storage engine type of a table.
1 comments
great
Post a Comment
Please put your comments here. your questions, your suggestions, also what went wrong with me.