note 54852 deleted from function.filesize by jacques
| From: | jacques@php.net | Date: | Mon, 18 Jul 2005 11:56:17 +0000 |
| Subject: | note 54852 deleted from function.filesize by jacques | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-92106@lists.php.net to get a copy of this message | ||
Note Submitter: mpb dot mail at gmail dot com
----
If you are working with files larger than 2GB (and PHP's integer type is only 32 bits on your
system) then you can try the following to get floating point sizes:
On FreeBSD:
$size = (float) exec ('stat -f %z '. escapeshellarg ($path));
On Linux:
$size = (float) exec ('stat -c %s '. escapeshellarg ($path));