note 28527 added to function.unlink
| From: | mascha at keipper dot NOSPAN dot de | Date: | Wed, 15 Jan 2003 23:51:45 +0000 |
| Subject: | note 28527 added to function.unlink | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-42196@lists.php.net to get a copy of this message | ||
You cant unlink() a file that you opened in the same script before with fopen().
If you try to unlink a file opened with fopen() earlier you will get a "permission denied"
php error - thats because the file was locked by fopen(), close the file pointer and then unlink()
the file!
This took me hours because I didnt know fopen() locks the file.
cheers,
m.k.
--
http://www.php.net/manual/en/function.unlink.php
http://master.php.net/manage/user-notes.php?action=edit+28527
http://master.php.net/manage/user-notes.php?action=delete+28527
http://master.php.net/manage/user-notes.php?action=reject+28527