PHP - Function chgrp()


Advertisements


Syntax

bool chgrp ( string $filename, mixed $group );

Definition and Usage

It attempts to change the group of the file filename to group.

Parameters

Sr.No Parameter & Description
1

filename

Path to the file.

2

group

A group name or number.

Return Value

Returns TRUE on success or FALSE on failure.

Example

Following is the usage of this function −

<?php
   $filename = "/home/httpd/html/index.php";
   chgrp ( $filename, "guest" );
?>

php_function_reference.htm