I don’t want an other application to read the files while this php app upload/overwrites files to the remote server
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There is no such thing as locking/unlocking files with ftp. Maybe some server can implement this kind of thing, but it should be non-standard. So, PHP is not managing this kind of thing.
By the way, depending your case, you can upload your file into a temporary directory and then rename it. Renaming is an atomic procedure, and it can be the right way to avoid your clients to download an non-finished upload file.