formie
formie copied to clipboard
Multi-page form submission failing when form contains File Upload field
Describe the bug
We have noticed an issue on a multi-page form, where the association to a file uploaded via the File Upload field goes missing when navigating back/forward in the form. This means when the user is on the final page, they cannot submit the form due to an error displayed on the mandatory File Upload field.
For the form I tested this on, the File Upload field is in a group; however, I tested this with another File Upload field and it suffered the same issue.
When I hard refreshed the page, the File Upload field displayed the association beneath the field. However, as soon as I navigated to another page the association was lost.
I think I have isolated the issue and it is caused by the AJAX form submission method. I switched to Page Reload and the File Upload field maintain its association and I was able to successfully submit the form.
Steps to reproduce
- Add a File Upload filed to a multi-page form
- Ensure AJAX is selected as the Submission Method
- Navigate to another page and then revisit the page with the File Upload field
Form settings
- Multi-page form: Yes
- Submission Method: Ajax
- Client-side Validation: Yes
- Custom Form Templates: No
Craft CMS version
4.9.1
Plugin version
2.1.18
Multi-site?
Yes
Additional context
This issue occurs in all environments