title: if statement for select option value
body: <p>I have a select option for departments on a html form. After the user submits the form. It emails the respective department manager. Now I have a value called $email which I want to use with the IF statement depending on what department is chosen. Eg. IF new car sales is selected then $email=newsales@gmail.com or IF used car sales is selected then $email=oldsales@gmail.com</p>
  
  <p>my code:</p>
  
  <pre><code>Department:&lt;br&gt; &lt;select name ="department"
              &lt;option value="ADMIN"&gt;ADMIN&lt;/option&gt;
              &lt;option value="AFTER-SALES DIRECTOR"&gt;AFTER-SALES DIRECTOR&lt;/option&gt;
              &lt;option value="ALPINE DEALER PRINCIPAL"&gt;ALPINE DEALER PRINCIPAL&lt;/option&gt;
              &lt;option value="AUTO ARMOUR/AUTO ENHANCE - FITMENT CENTRE (Smash and Grab)"&gt;AUTO ARMOUR/AUTO ENHANCE - FITMENT CENTRE (Smash and Grab)&lt;/option&gt;
              &lt;option value="BANDIT-VW"&gt;BANDIT-VW&lt;/option&gt;
              &lt;option value="BOOKINGS VW"&gt;BOOKINGS VW&lt;/option&gt;
              &lt;option value="DRIVEWAY/WASHBAYS"&gt;DRIVEWAY/WASHBAYS&lt;/option&gt;
              &lt;option value="FINANCE AND INSURANCE"&gt;FINANCE AND INSURANCE&lt;/option&gt;
              &lt;option value="IT DEPARTMENT"&gt;IT DEPARTMENT&lt;/option&gt;
              &lt;option value="MARKETING DEPARTMENT"&gt;MARKETING DEPARTMENT&lt;/option&gt;
              &lt;option value="MASTER CARS"&gt;MASTER CARS&lt;/option&gt;
              &lt;option value="MAYOR OF PINETOWN"&gt;MAYOR OF PINETOWN&lt;/option&gt;
              &lt;option value="NEW CAR PREP DEPARTMENT"&gt;NEW CAR PREP DEPARMENT&lt;/option&gt; 
              &lt;option value="NUMBER PLATES"&gt;NUMBER PLATES&lt;/option&gt;
  &lt;/select
  </code></pre>