title: header(); not working after log out ]session_destroy()]
body: <p>I have this code for my logout.php:</p>
  
  <pre><code>&lt;?php
  
  session_start();
  
  $_SESSION = array();
  
  if (ini_get("session.use_cookies")) {
  $params = session_get_cookie_params();
  setcookie(session_name(), '', time() - 42000,
      $params["path"], $params["domain"],
      $params["secure"], $params["httponly"]
  );
  }
  
  session_destroy();
      header( "Location: index.php" ); //to redirect back after logging out
  ?&gt;
  </code></pre>
  
  <p>Problem is that the header doesn't work. I don't know if it has anything to do with the code above.. but I don't think so, cause it works on localhost - wamp server. Is it then because of the server I'm using? Or is it something wrong in the code?</p>
  
  <p>Thanks!</p>