title: Simple PHP Form Redirect
body: <p>I'm trying to create a simple redirect on this form. The form sends an email when I click submit, but it won't redirect to the url I specified.</p>
  
  <p>Here's my PHP code:</p>
  
  <pre><code>&lt;?php if ($valid_message)
  {
  header("Location: http://www.beulahprint.ie/energycentre.php");
  exit();
  }
  else {print "We encountered an error sending your mail"; }
      $to = "colm@beulahprint.ie";
      $subject = "Web Contact Form";
  
      $email = $_REQUEST['email'] ;
      $message = $_REQUEST['message'] ;
  
      $headers = "From: $email";
      $sent = mail($to, $subject, $message, $headers) ;
  ?&gt;
  </code></pre>