Jump to content

[SOLVED] New Directories have Incorrect Permissions


Edward

Recommended Posts

 

Hi,

 

I'm building an FTP site. I am manually creating my root folder via an FTP programme and setting the permissions to 777 (which I believe is required). When I check who the owner of this folder is, its 32414 (As far as I'm aware, I don't need to take any notice of what this means). I have a form on the site which people can fill out to create new directories, which will result in the following code being run:

 

if ($result_folder = mkdir($path.$id, 0777)) {
				# if the new folder was created, do this:
				$file = 'index.php';
				$file_copy = $path.$id.'/index.php';
				copy($file, $file_copy);
				echo '<p>Thank you '.$creater.', the folder \''.$name.'\' has been created.</p>';
				echo '<p>Would you like to <a href="add_a_folder.php">add another folder</a>?</p>';
			}

 

When this is done, I notice that the actual permissions of the new subdirectory are not 777, but instead are 755, the owner is 99. This means that I can't manually delete the folder via my ftp programme and my domain will become untidy and crowded. Do you know how to get the correct permissions to be setup, and if I need to specify who the owner is?

 

Thank you in advance.

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.