Imagine a form with a file field. It invites the user to uploade, say, their CV. A first user have a file named cv.pdf. A second user have one file named the same way. If both user apply, it seems that the first user’s CV will be overwritten.
How to avoid this? I would ideally like to suffix the file names, or if not possible to upload to a different subfolder. For that second option, can I do something like destination: /user/data/cvs/{{ form.value.name|e }}maybe?
Great, thanks for the quick updates!
So can I update my version of the Form plug-in with the one on Github? Or could that cause issues, with the auto-updater or something else?
Actually, the update also broke another form without a file field. The Missing required field in that case is the ReCaptcha field (the last one before the Submit button).
Mmm cannot replicate. Are you using Grav 1.1? I am testing on that. Or 1.0? Care to open an issue on the Form plugin repo https://github.com/getgrav/grav-plugin-form so we can better track this?
I am using 1.0.10. So I reverted back to the 1.1.2 version of the Form plugin because the site goes into production this week. I simply added your latest commit to the form.php file: