This example of chgrp() function in PHP. The chgrp() function is used to change the group permission for the file. To use the example you have to provide the name of the file and the group name to the chgrp() function. This function can be used to change the group from PHP file.
syntax
bool chgrp ($file ,$group)
Change the filename's current user group to other usergroup .It works on Unix based o/s.
Return true or false
code
<?php
$a=chgrp("c:/rose1/ss.java","admin");
echo $a;
?>
output
1
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.