This is a script that i use to make dir and copy files when a user requests it.
Appaerntly the script works good, but how do i set it to change the goup for the files like the folder. Cause when i go to delete the files i cant. Is there a way to make the file 0777 like the folder.
<?php
$syspath = ("home/datad967/public_html/fs");
if (mkdir("/$syspath/$username", 0757))
{
echo "Your File Server Was Created Successfully!";
}
else
{
echo "The File Server Your Choosen Has Been Taken";
}
?>
<br>
<?php
if(copy("files/index.php", "$username/index.php"))
{
print("yes");
}
else
{
print("no");
}
?>
<br>
<?php
if(copy("files/config.php", "$username/config.php"))
{
print("yes");
}
else
{
print("no");
}
?>
<br>
<?php
if(copy("files/upload.php", "$username/upload.php"))
{
print("yes");
}
else
{
print("$no");
}
?>