php-windows Digest 7 Jul 2005 05:35:45 -0000 Issue 2720
Topics (messages 26188 through 26188):
disk_free_space and disk_total_space works for only one drive
26188 by: Dan Fulbright
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[email protected]
----------------------------------------------------------------------
--- Begin Message ---
I wrote a script to check disk usage. Here's the meat of it:
$free = round(disk_free_space($partition) / 1024 / 1024, 0);
$total = round(disk_total_space($partition) / 1024 / 1024, 0);
echo "$partition: $free MB free, $total MB total\n";
With $partition = "D:", it works fine. Note that the script itself is on
D:. With any other drive, it just shows 0 for $free and $total.
This script works fine on Apache and Linux, but not with IIS and
Windows. It does work using PHP on the command line in Windows, though.
Could it be a permissions issue?
I'm using PHP 4.3.10, IIS 6.0, Windows Server 2003.
Thanks in advance.
--df
--- End Message ---