Using Freeform Next. I have a feeling this is way basic and Im just missing it.

I have a dynamic recipients set up with on a "Select Division" drop down.

Currently the email is returning the email address Im filtering too. I want the option label of the division.

How do I get that?

Basic form is ....

Contact Form Submitted on: {current_time format="%l, %F %j, %Y at %g:%i%a"}

  • Name: {field:name:value}
  • Email: {field:email:value}
  • Phone Number: {field:phone:value}
  • Division: {field:division:options}{option:label}{/field:division:options}
  • Message: {field:message:value}
  • I am having the same issue, were you able to solve this? I would like to display the label of the division the user selected. – DigitalDesigns Feb 2 at 17:41

Have you set up a custom email notification template for the form? You should be able to add {field:division:label} and {field:division:value} to the body and whatever other variables from the form you want displayed in the notification email. https://solspace.com/expressionengine/freeform/docs/email-notifications/#email-body

I've just found a workaround for this, although it's not very elegant.

On my Dynamic Recipients field, I have 2 options available. Each one has 2 email addresses, which the Notifications will be sent to, upon the customer submitting the form.

Option A = email1@domain.com,email2@domain.com
Option B = email3@domain.com,email4@domain.com

In my Notifications template, I have then added an if..then..else check to detect which values (as a string) have been submitted, for this Field.

<tr>
    <th>{field:fieldname:label}</th>
    <td>{if field:fieldname:value == "email1@domain.com,email2@domain.com"}Option A{if:else}Option B{/if}</td>
</tr>

So far, in testing, this has proven successful. It's a bit clunky because if you change the destination email addresses on the form Field, you have to remember to edit them in the if..then..else statement too.

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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