-
Adam_LaRosaAsked on March 21, 2025 at 1:09 PM
Is there any way to prevent a user from uploading the same picture twice in a particular submission? Our previous survey provider allowed us to write a custom javascript that stored the file names in an array through out the form with a condition to through an exception when a previously used filename was discovered. Are there any work arounds for this or does JotForm offer customizable Javascript that we could leverage to accomplish similar?
-
Joseph Christian JotForm SupportReplied on March 21, 2025 at 2:00 PM
Hi Adam,
Thanks for reaching out to Jotform Support. I’ll need a bit of time to look into this. I’ll get back to you as soon as I can.
Thanks for your patience, we appreciate it.
-
Joseph Christian JotForm SupportReplied on March 21, 2025 at 2:36 PM
Hi Adam,
Unfortunately, it's currently not possible to add JavaScript directly to the form for security reasons. Also, I tested this, and Jotform automatically appends a random number to the file name when the same file is uploaded in either the same File Upload field or a different one. Checkout my screencast below to see my results:
Let us know if you need any other help.
Your Answer
Something Went Wrong
An error occurred while generating the AI response. Please try again!