chgroup() function updates the file group. Remember, only superuser has permission to arbitrarily change the file's group,
chgroup($file_path, group)
file_path -Set the path of the file or directory to be checked. Required.
group -Set the new user group name or number.
chgroup() function returns.
The following example checks the file "one.txt" and changes its filegroup.
TRUE TRUE
The above is the detailed content of The role of the chgrp() function in PHP is to change the user group to which a file or directory belongs.. For more information, please follow other related articles on the PHP Chinese website!