Scott Fletcher wrote:
Hi!
How do we tell if the file is already locked when someone use a flock() on the file??
FletchSOD
Do you mean within PHP code? If that's the case then this is taken care of by the flock() function... it checks the file's status and based on the parameter(s) that you use it will give you access or not. I believe that if another script tries to access the file but doesn't try to flock() it then they can simply do whatever they want with the file (someone correct me here if I'm wrong).
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php