php - Test writing to file at the same time as anyone else using file_put_contents -
I have a form on the page that after submitting its content the file has been written using file_put_contents. I use LOCK_EX to lock while locking the file. But there is a way to do that it really works and it happens to see that when the file is called twice at the same time.
$ answer = file_put_contents ($ file, $ skier, FILE_APPEND | LOCK_EX);
Thank you in advance
you launch En Bet / Shell You can try to execute your PHP code at the same time and access the same file
Comments
Post a Comment