from = $data['Email'];   // Careful with this - some email servers could ignore because of the from being different to the server that's sending the email
      $email->to = '[email protected]';
      $email->subject = 'The contact page has been submitted';
      $email->populateTemplate(array(
         'FormData' => new ArrayData($data)
      ));
      $email->send();

      Director::redirect('finished-page');  // Redirect to the page with the URLSegment 'finished-page'
   }

?>