Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I would like to send an email confirmation to the user after he submit the form. But also I want to know if it's possibile to choose which email handler to use dependant on a checkbox value of the form.
So if the users checks the optional field, they will recive the email of type 'A'.
Otherwise they will receive an email of type 'B'
The simplest way I can think of to implement this would be to create multiple fields so that one is associated with each handler. You would then dynamically populate these fields based on the checkbox chosen (if it's just the one checkbox, then that'd just be two fields).
You can then configure each handler to use either of those fields as the dynamic recipients field.
The challenge would be to handle the situation where the other handler doesn't send an email. That might cause an error, or Formulate might just ignore it and not send the email. You'll have to experiment with that. If it doesn't ignore it and causes an error, then one option would be to create a dummy email address (e.g., [email protected]) that gets all the emails you don't care about.
So HandlerA is configured to send to DynamicEmailsA and HandlerB is configured to send to DynamicEmailsB. Then populate DynamicEmailsA and DynamicEmailsB based on whether or not Checkbox1 is selected.
There is a server side event you can use to perform this check and dynamically populate the field values. Here are some details about that: https://code101.net/code-101/dynamic-email-recipients-with-umbraco-formulate
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted