Learning PHP
Advanced PHP
PHP Function Reference
PHP Useful Resources
Selected Reading
© 2011 TutorialsPoint.COM
|
PHP Function filegroup()
Syntax
int filegroup ( string $filename );
|
Definition and Usage
Gets the file group. The group ID is returned in numerical format, use posix_getgrgid() to resolve it to a group name.
Paramters
Parameter | Description |
filename | Path to the file. |
Return Value
Returns the group ID of the file, or FALSE in case of an error. The group ID is returned in numerical format, use posix_getgrgid() to resolve it to a group name. Upon failure, FALSE is returned.
Upon failure, an E_WARNING is emitted.
Example
Following is the usage of this function:
<?php
$filename = "/home/httpd/html/index.php";
$group = filegroup($filename);
echo "File group is $group\n";
?>
|
This will produce following result:
|
|
|