1

The confirmation emails sent by webform (running under Drupal 8.9.7) on submission are in the USA format (m/d/Y) for all date fields submitted by users on the form, differently from the system generated dates, like the the form submission date, which are in UK format).

I need to change the format for the dates submitted by user to the UK format too, as that is what my users expect.

Web research tells me that the Webform module picks the date format for emails from the system's default medium date, but this doesn't happen in my case, as that is set to D d/m/Y - H:i. What I get for the user submitted date fields is D, m/d/Y - H:i.

I have changed the default date format, but nothing changes.

Guidance on how to fix or on a workaround would be appreciated.

0

1 Answer 1

2

I have a work-around, but not a solution:

  • Go to /admin/structure/webform/config/elements
  • In the section "Element Formats" change "Date/Time" from "- default -" to "Default medium date (medium)"
1
  • How is this not a solution? Create your custom date/time format in admin/config/regional/date-time and select it as you described above. Worked fine for me.
    – MrUpsidown
    Jul 13, 2022 at 11:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.