Jump to content

Archived

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

tomfmason

setting permissions for a directory on creation (windows)

Recommended Posts

I have an issue. I have created several temp directories and when I am done with them I want to delete them. Well I keep getting the error Permission denied. I think that I have set the permissions properly for the apache group and I could easily delete the file manuly but I don't want to do that.

When I look at the properties for that directory I see that it is read only. Why is this. I am using the following code to create the dir.

[code=php:0]
$dir = "./" . $_SESSION['username'] . "." . date(Ymd);
if (is_dir($dir) == false) {
   mkdir($dir);
}
[/code]

Any suggestions as to why this file is being created with read only access?

Share this post


Link to post
Share on other sites
Yes, everyone on a shared hosting has the problem.

No one as of yet showed a solution that doesn't invole php ftp.

http://ca.php.net/mkdir

read the comment by "Han Van den Hoof"

Share this post


Link to post
Share on other sites

×

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.