note 25676 added to function.chmod
| From: | kvogt at shaw dot ca | Date: | Wed, 02 Oct 2002 04:36:35 +0000 |
| Subject: | note 25676 added to function.chmod | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-37508@lists.php.net to get a copy of this message | ||
I set my directory's sticky bit on, perform a task, and then unset the sticky bit. My
directory's regular permissions are 701. On the command line (Open BSD 3.0) I would go chmod
1701 /path/to/dir to turn sticky on, and then chmod 0701 /path/to/dir later to turn it off. I got
this working in PHP by going chmod('/path/to/dir',octdec(1701)) and then
chmod('/path/to/dir/',octdec(701)) later. Notice that I specified 701 rather than 0701 in
the second call. I got strange permission errors when I did chmod(...,octdec(0701)). Although there
is perhaps something there I don't understand
--
http://www.php.net/manual/en/function.chmod.php
http://master.php.net/manage/user-notes.php?action=edit+25676
http://master.php.net/manage/user-notes.php?action=delete+25676
http://master.php.net/manage/user-notes.php?action=reject+25676