Learning PHP
Advanced PHP
PHP Function Reference
PHP Useful Resources
Selected Reading
© 2013 TutorialsPoint.COM
|
PHP Function diskfreespace()
Advertisements
Syntax
|
float diskfreespace ( string $directory );
|
Definition and Usage
This function is an alias of: disk_free_space().
Paramters
| Parameter | Description |
| directory | A directory of the filesystem or disk partition. |
Return Value
Returns the base name of the given path.
Example
Following is the usage of this function:
<?php
//On windows:
$hdwinC = diskfreespace("C:");
$hdwinD = diskfreespace("D:");
echo "Diskspace left on C: $hdwinC";
echo "Diskspace left on D: $hdwinD";
//Linux:
$hdGnu = diskfreespace("/");
echo "Diskspace left on / $hdGnu";
?>
|
Advertisements
|
|
|