note 66442 added to function.filesize

From: Date: Mon, 22 May 2006 20:57:55 +0000
Subject: note 66442 added to function.filesize
Groups: php.notes 
Request: Send a blank email to php-notes+get-111836@lists.php.net to get a copy of this message
HiHo! I modified the note of php dot net at alan-smith dot no-ip dot com cause i guess that's might be an endless while clause! <? function resize_bytes($size) { $count = 0; $format = array("B","KB","MB","GB","TB","PB","EB","ZB","YB"); while(($size/1024)>1 && $count<8) { $size=$size/1024; $count++; } $return = number_format($size,0,'','.')." ".$format[$count]; return $return; } ?> Anyway gratz! Nice idea thx ;) ---- Server IP: 217.160.72.57 Probable Submitter: 84.132.212.122 ---- X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER autolearn=no version=2.64 ---- Manual Page -- http://www.php.net/manual/en/function.filesize.php Edit -- http://master.php.net/note/edit/66442 Del: integrated -- http://master.php.net/note/delete/66442/integrated Del: useless -- http://master.php.net/note/delete/66442/useless Del: bad code -- http://master.php.net/note/delete/66442/bad+code Del: spam -- http://master.php.net/note/delete/66442/spam Del: non-english -- http://master.php.net/note/delete/66442/non-english Del: in docs -- http://master.php.net/note/delete/66442/in+docs Del: other reasons-- http://master.php.net/note/delete/66442 Reject -- http://master.php.net/note/reject/66442 Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#111836) next »