Answers.Body: <p>A custom dropdown that allows you to trigger emails to different departments is possible using <a href="http://sprout.barrelstrengthdesign.com/craft-plugins/forms" rel="nofollow">Sprout Forms</a> and the Sprout Fields <a href="http://sprout.barrelstrengthdesign.com/craft-plugins/fields/docs/overview/email-select-field" rel="nofollow">Email Select</a> field.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-08-13T14:50:24.833Z
Answers.LastActivityDate: 2016-08-13T14:50:24.833Z
Answers.UserDisplayName: Ben Parizek
Answers.Body: <p>There isn't a way to do this natively with the plugin, so you'd end up having to fork the plugin and adding your own custom business logic.</p>
  
  <p>Currently the plugin is set to only send to one "To Email" globally under its settings.</p>
  
  <p>Your fork would probably need to change that in the settings page to a dropdown for each of your defined sections and to be able to specify an email address for each one.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-09-19T15:42:46.490Z
Answers.Text: @brad something like this isn't possible?
  
  `<select name="toEmail">
                          <option value="example@me.com">General</option>
                          <option value="example2@me.com">Bookings</option>
                        </select>`
Answers.UserDisplayName: John Johnson
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-08-13T04:33:31.870Z
Answers.LastActivityDate: 2016-08-13T04:33:31.870Z
Answers.UserDisplayName: Brad Bell
Answers.Body: <p>It is possible to do this, on a website with Craft 2 I used the following </p>
  
  <pre><code>     &lt;div class="select-wrapper"&gt;
       &lt;select name="toEmail" id="toEmail"&gt;
       &lt;option value=""&gt;- Velg -&lt;/option&gt;
       &lt;option value="{{ 'email@address.com'|hash }}"&gt;Name of recipient&lt;/option&gt;
       &lt;option value="{{ 'email@address.com'|hash }}"&gt;Name of recipient&lt;/option&gt;
       &lt;option value="{{ 'email@address.com'|hash}}"&gt;Name of recipient&lt;/option&gt;
       &lt;option value="{{ 'email@address.com'|hash }}"&gt;Name of recipient&lt;/option&gt;
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-04-16T07:23:07.527Z
Answers.LastActivityDate: 2019-04-18T05:35:10.590Z
Answers.LastEditDate: 2019-04-18T05:35:10.590Z
Answers.UserDisplayName: Bcdo
Body: <p>I need to give users the ability to be able to choose which channel of the company their message goes to, i.e. General Inquiries, Estimates etc. using the <a href="https://github.com/pixelandtonic/ContactForm" rel="nofollow noreferrer">P&amp;T Contact Form Plugin</a> and a <code>select</code> box. How would I be able to make that work?</p>
  <p>Thanks!</p>
  
Tags: <templating><plugin-contactform>
Title: Recipients as dropdown with Contact Form Plugin
ThreadText: # Recipients as dropdown with Contact Form Plugin
  
  (Asked by: username_0 on 2016-08-12)
  
  I need to give users the ability to be able to choose which channel of the company their message goes to, i.e. General Inquiries, Estimates etc. using the [P&T Contact Form Plugin](https://github.com/pixelandtonic/ContactForm) and a `select` box. How would I be able to make that work?
  
  Thanks!
  
  **Tags:** templating, plugin-contactform
  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_1 on 2016-08-13. Score: 3 | Accepted answer
  
  A custom dropdown that allows you to trigger emails to different departments is possible using [Sprout Forms](http://sprout.barrelstrengthdesign.com/craft-plugins/forms) and the Sprout Fields [Email Select](http://sprout.barrelstrengthdesign.com/craft-plugins/fields/docs/overview/email-select-field) field.
  
  
  ---
  
  ### Answer by username_2 on 2016-08-13. Score: 2
  
  There isn't a way to do this natively with the plugin, so you'd end up having to fork the plugin and adding your own custom business logic.
  
  Currently the plugin is set to only send to one "To Email" globally under its settings.
  
  Your fork would probably need to change that in the settings page to a dropdown for each of your defined sections and to be able to specify an email address for each one.
  
  > **Comments:**
  > **username_3**: @username_2 something like this isn't possible?  `<select name="toEmail">                         <option value="example@me.com">General</option>                         <option value="example2@me.com">Bookings</option>                       </select>`  
  
  ---
  
  ### Answer by username_4 on 2019-04-16. Score: 1
  
  It is possible to do this, on a website with Craft 2 I used the following
  
  ```
       <div class="select-wrapper">
       <select name="toEmail" id="toEmail">
       <option value="">- Velg -</option>
       <option value="{{ 'email@address.com'|hash }}">Name of recipient</option>
       <option value="{{ 'email@address.com'|hash }}">Name of recipient</option>
       <option value="{{ 'email@address.com'|hash}}">Name of recipient</option>
       <option value="{{ 'email@address.com'|hash }}">Name of recipient</option>
  
  ```
  
  
  ---
  
  