I want to upload file with have only file path in php. Can anyone guide me how can I do. Now, I am developing a webpage that allow the user to upload file but when they submit we do not upload the files immediatly we keep files path and process uploading in another page. Please guide me how can I do, or I have to change my way to do it. Thank in advance.
Share
No, that is not possible, for technical/security reasons: there is no way to set the file to be uploaded, except by user interacting with the upload box (because otherwise a malicious page could grab any file of the user).
What you could do is have the file upload as a separate form in an iframe (e.g. this is a useful JavaScript wrapper for that), upload the file first, and keep a reference to the file you now have on your server until the point when you actually need it in the main form.