How to convert values from select multiple into an email?

113 Views Asked by At

How can I convert the selected options from a select multiple field into an email?

<select name="fields[issues][]" multiple="multiple">
     <xsl:for-each select="//issues-all/entry">
         <option value="{@id}">
           <xsl:value-of select="title"/>
         </option>
     </xsl:for-each>
</select>

My standard approach doesn't work unfortunately:

<input name="send-email[body]" value="fields[name,address,phone,issues]" type="hidden" />

The email gets delivered but contains the value as a string rather than the actual values.

What am I missing here?

Thanks for any help.

2

There are 2 best solutions below

0
On

Assuming this isn't a bug and the standard Symphony email event isn't supposed to be able to select options, it sounds like a job for Email Template Manager.

0
On

You should be able to also use:

<input name="send-email[body]" value="fields[name],fields[address],fields[phone],fields[issues]" type="hidden" />

As David mentioned though, Email Template Manager or Email Template Filter are great extensions to help you build more custom emails.