Webform won't submit when an file input is present on the form

Created on 9 September 2021, over 3 years ago
Updated 3 September 2024, 4 months ago

Drupal: 8.9.18

We have a simple webform on a page that includes a file input field. When a file input field is present on the webform and the form is submitted, the user is redirected to the same page with their information still present in the form. The form is setup to redirect the user to a thank you page when the form has been completed, this doesn't happen.

When we remove the file input from the form, the submit submits fine and redirects the user to the thank you page.

I have enabled verbose logging, there are no errors appearing and there are not errors showing in the log messages section of Drupal.

After the form is submitted, the user is shown their information in the form, and this seems to indicate to me some sort of issue/validation problem with the form?

Any advice would be appreciated.

πŸ› Bug report
Status

Closed: cannot reproduce

Version

6.0

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom shepparddigital

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡§πŸ‡ͺBelgium waropd

    Problem is still present.

    When the webform gets rendered in an ajax modal the problem still occurs.

  • Status changed to Postponed: needs info almost 2 years ago
  • Please post a minimal example form.

  • Status changed to Closed: cannot reproduce over 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States jrockowitz Brooklyn, NY

    Without an example we can't reproduce this issue.

  • Hello
    exactly the same problem here, desrciption abvoe matches 100%.
    Both on live (d9.5.11, webform 6.2) and backup (d.9.4.8, webform 6.1.3.)
    Which info could we provide in order to reproduce the bug?
    Any advice would be appreciated!

  • Hello ,
    we could finally detect the error:
    Our custom theme places an icon within the submit button (left to text).
    This "manuipulation" blocked the submisison of the form.
    Submission works fine without that icon (or with Olivero activated).
    Best regards

  • Had a similar issue. The cause was a JavaScript validation event listener that ran on submit. The form didn't like it. Changed our form to use custom server side validation instead.

Production build 0.71.5 2024